Author Topic: How to use else if for username Elastic skin ?  (Read 1267 times)

Offline japjitravel

  • Newbie
  • *
  • Posts: 2
How to use else if for username Elastic skin ?
« on: April 09, 2020, 08:21:20 AM »
I have install roundcube with elastic skin, now i want to use else if for username for below code
<roundcube:object name="username" />

I want to check if user1 logged in then hide _bcc else show just like below

<roundcube:if condition="env:username=='user1@xxx.com'" />
hide bcc field
<roundcube:else />
show bcc field
<roundcube:endif />

can anyone help me to do like this

Offline JohnDoh

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2,472
Re: How to use else if for username Elastic skin ?
« Reply #1 on: April 09, 2020, 12:50:18 PM »
the current username is stored in the session so you want:
Code: [Select]
<roundcube:if condition="session:username=='user1@xxx.com'" />
Roundcube Plugins: Contextmenu, SpamAssassin Prefs, and moreā€¦