You need to sign in to do that
Don't have an account?
Tyler Zika
Embed styling into Visualforce if statement
I want to add style to the output of a Visualforce IF statement.
How would I add bold tags to End Time: (<b>End Time: </b>) ?
When I do add bold tags in the if statement it takes them as a string and doesn't style it as bold.
<li>{! IF( ISBLANK(GoEvent.Event_Time_End__c), '', "End Time: "+GoEvent.Event_Time_End__c+"" ) }</li>
How would I add bold tags to End Time: (<b>End Time: </b>) ?
When I do add bold tags in the if statement it takes them as a string and doesn't style it as bold.
<apex:outputText value="{! IF( ISBLANK(Contact.Owner.Email), '', "<b>End Time:</b> "+Contact.Owner.Email+"" ) }" escape="false"/>
All Answers
so it reads <li style='{! IF( ISBLANK(GoEvent.Event_Time_End__c), "", "font-weight:bold;" ) }'>{! IF( ISBLANK(GoEvent.Event_Time_End__c), '', "End Time: "+GoEvent.Event_Time_End__c+"" ) }</li>
<apex:outputText value="{! IF( ISBLANK(Contact.Owner.Email), '', "<b>End Time:</b> "+Contact.Owner.Email+"" ) }" escape="false"/>