0

This is my css that I am applying on one td. But this is not working in IE,FF and other browsers.

 $("#tdTopMenu").css({ "backgroundColor": "003f60", "height": "17pt", "display": "block", "white-space": "nowrap", "min-width": "1250px" });

Whereas If I write one line

<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" />

then its started showing in IE only not in other browsers. Please help

1
  • replace "backgroundColor": "003f60" on "background-color":"#003f60" and will work Commented Oct 10, 2013 at 13:03

2 Answers 2

5

003f60 is not a colour. #003f60 is. Make sure the CSS you are trying to apply is valid.

Sign up to request clarification or add additional context in comments.

3 Comments

Also backgroundColor should be background-color.
@mzohreh according to api.jquery.com/css both notations are viable, backgroundColor and background-color. The only difference is that you don't need quotations around backgroundColor.
@mzohreh Not only backgroundColor, other style like fontWeight, marginLeft, marginRight, etc., is there
0

put #003f60 instead of 003f60 because you must put # before the property like below

$("#tdTopMenu").css({ "background-Color": "#003f60", "height": "17pt", "display": "block", "white-space": "nowrap", "min-width": "1250px" });

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.