Link to home
Start Free TrialLog in
Avatar of Pete Winter
Pete WinterFlag for United Kingdom of Great Britain and Northern Ireland

asked on

select menu css not working in some browsers

Why is my css styling not working in some browsers?

<select name="filter_option" id="filter_option" style="font-size:14px;">
            <option value="xxxx">xxxx</option>
            <option value="zzzz">zzzz</option>
          </select>

i.e. Fonts size should be 14px, but doesn't seem to change in IE and Safari. Does in firefox?

Any idea's?
Avatar of SSupreme
SSupreme
Flag of Belarus image

The em size unit is recommended by the W3C.

try this: 0.875em
<select name="filter_option" id="filter_option" style="font-size:0.875em;">
            <option value="xxxx">xxxx</option>
            <option value="zzzz">zzzz</option>
          </select>
also add body {font-size:100%;} to your CSS, and you will end up with same text size in all browsers.
Avatar of Pete Winter

ASKER

Thanks, but the text size between browsers is still not the same.

For example if you use 2em the text is very larger in IE and firefox, but it still quite small in safari?
ASKER CERTIFIED SOLUTION
Avatar of SSupreme
SSupreme
Flag of Belarus image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Thanks for your help.