Forum Moderators: open

Message Too Old, No Replies

fonts in pulldown options

option,select,font,bold,color

         

lmfzor

8:11 am on Feb 23, 2006 (gmt 0)

10+ Year Member



I am listin options from an array
(index1,value1,status1,index2,value2,status2......)
I want to present the "value" in a pulldown menu
in a grey font if the "status" is zero and bold font
if the status is one.
This does NOT work........................
echo '<select name="idx" >';
for($i=0;$i<count($Arr)-1;$i+=3)
{ if ($Arr[$i+2]==0)
{
echo '<option value="'.$Arr[$i].'" >.
'<font color="grey">'.$Arr[$i+1].
'</font></option>';
}
else
{
echo '<option value="'.$Arr[$i].'" >'.
'<b>'.$Arr[$i+1].'<b></option>';
}
}
echo '</select >';

BlobFisk

9:27 am on Feb 23, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hi Imfzor you need to use CSS to do this rather than the deprecated font tag.

option { color: #999 }

For example...