PDA

View Full Version : User Profile Field Conditional


Kirk Y
07-06-2005, 01:44 AM
I'm new to the "if conditions". I'm trying to set it up so that if the user's profile field has a certain option then a certain image is displayed. I've got the profile field set up, I just can't figure out what I should place in the template.

This is what I have right now, but it's not working:
<if condition="$vbulletin->userinfo['field10'] == 'Yes'">

Help? Please. :ninja:

Andreas
07-06-2005, 01:46 AM
What type of Profilefield is field10?

Kirk Y
07-06-2005, 06:02 AM
A Single-Selection Menu.

Edit: Nevermind, I was browsing the Forum and found a Country Flag Hack.

<if condition="$post[fieldxx]"><img src="http://your.domian/flags_dir/$post[fieldxx].gif" border="0" alt="country flag" /><br /></if>

Just replace the "xx" with the field number. ;)