addClass
HTML
<div id='wrapper'>
<button id='add'>Add Class</button>
<button id='remove'>Remove Class</button>
<div id='main'>
Main DIV
</div>
</div>
CSS
#main{
position:relative;
width:250px;
height:100px;
background:#e7e7e7;
}
.customClass{
color:#F00;
width:500px !important;
}
JavaScript
$("#add").click(function(){
$("#main").addClass('customClass');
});
$("#remove").click(function(){
$("#main").removeClass('customClass');
});