html - How to give an option tag font-weight: bold in Chrome? -


i want show select option's text in bold, below image. code working fine in browsers except chrome. how can solve problem?

<select style="font-weight:normal">   <option style="font-weight:bold">bold text here</option>   <option style="font-weight:bold">bold text here</option>   <option style="font-weight:bold">bold text here</option>   <option style="font-weight:bold">bold text here</option> </select> 

could give more informations need ??

for exemple : if need make bold selected option, used hack this, when select option, become bold:

fiddle : http://jsfiddle.net/gt7yq/

html :

<select>     <optgroup id='111' label="111" style="display:none"></optgroup>     <option value="111">111</option>      <optgroup id='222' label="222" style="display:none"></optgroup>     <option value="222">222</option>  </select> 

js :

$('select').on('change',function(){     $('optgroup').hide();     $('select option').show();     $('select option:selected').hide();     $('#'+$('select option:selected').val() ).show(); }); 

but if want show special option, if it's not selected... can't you... (but answer interrest me)


Comments

Popular posts from this blog

java.util.scanner - How to read and add only numbers to array from a text file -

rewrite - Trouble with Wordpress multiple custom querystrings -