Click here to Skip to main content
15,937,012 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a css class like below,

    border-collapse: collapse;
    border-style: solid;
    border-width: 1px 1px 0 0;
    display: table-cell;
    line-height: 0.3em;
    overflow: hidden;
    padding: 0.7em;
    white-space: nowrap;

I want to remove line-height : 0.3em, white-space : nowrap from the css class(myclass). How to do this using jquery?

The most sane way to do this is to have two sets of CSS and apply the ones you want from page to page. However, as google works where I live, I found this[^], which looks like it should help.
Share this answer
thatraja 11-Aug-11 2:09am    
That's the right way, 5!
You might want modify the existing css attribute using the css function and specify the default values for the attributes. Or as Christian said, create 2 sets of CSS, and then use toggleClass to switch from one class to the other.
Share this answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900