2012-01-03, 10:56 AM
I need a simple If statement.
<span style="color: ? >(word)</span>
the ? should be an IF statement.
I'm using a custom profile field in which members can note down a color code, then the word should be displayed in that color they specified in the custom profile field, but if they don't put anything in the profile field and it is thus empty, the word should be displayed in green automatically.
Can you guys help me with finding the right IF-statement for this?
The name of the custom profile field btw is {$post['fid4']}
Thanks in advance
Never mind, already solved without the use of an IF-statement, just put:
<span style="color: green; color: {$post['fid4']};">(word)</span>
<span style="color: ? >(word)</span>
the ? should be an IF statement.
I'm using a custom profile field in which members can note down a color code, then the word should be displayed in that color they specified in the custom profile field, but if they don't put anything in the profile field and it is thus empty, the word should be displayed in green automatically.
Can you guys help me with finding the right IF-statement for this?
The name of the custom profile field btw is {$post['fid4']}
Thanks in advance
Never mind, already solved without the use of an IF-statement, just put:
<span style="color: green; color: {$post['fid4']};">(word)</span>