Trying to set the background colour for individual drop down items using
JS -
////////////////////////////////////////////////////////////////////////////
//////////////////////
var ctrl = getElementByID( 'busresid');
ctrl.options[2].style="backgro und-color:#FF0000";
////////////////////////////////////////////////////////////////////////////
//////////////////////
in jsp page can set it no problem like -
////////////////////////////////////////////////////////////////////////////
//////////////////////
<select id='busresid''>
<option style="backgrou nd-color:#FF0000"> Red</option>
<option style="backgrou nd-color:#FFFF33 ">Amber</option>
<option style="backgrou nd-color:#00FF00 ">Green</option>
</select>
////////////////////////////////////////////////////////////////////////////
//////////////////////
any ideas?
thanks
harry
JS -
////////////////////////////////////////////////////////////////////////////
//////////////////////
var ctrl = getElementByID( 'busresid');
ctrl.options[2].style="backgro und-color:#FF0000";
////////////////////////////////////////////////////////////////////////////
//////////////////////
in jsp page can set it no problem like -
////////////////////////////////////////////////////////////////////////////
//////////////////////
<select id='busresid''>
<option style="backgrou nd-color:#FF0000"> Red</option>
<option style="backgrou nd-color:#FFFF33 ">Amber</option>
<option style="backgrou nd-color:#00FF00 ">Green</option>
</select>
////////////////////////////////////////////////////////////////////////////
//////////////////////
any ideas?
thanks
harry
Comment