Possible Duplicate:
Get back default properties after applying a global CSS reset
I want to set all CSS properties for an object to whatever the default value for that property is.
var element = this.get(0); // from jQuery
var props = [];
for (var prop in element.style)
props.push(prop);
return;
I need to override an existing stylesheet is why.
e.g.:
display:default !important;
color:default !important;
border-radius:default !important;
line-size:default !important;
or
display:!important;
color:!important;
border-radius:!important;
line-size:!important;
*not just those styles. all styles
You can use the initial keyword to restore the default value of a CSS property.
To restore every property to it’s initial value, you’ll have to manually add every property to the element’s
styleattribute with a value of “initial”.