审议以下事项:
<style type = text/css >
.c1
{
opacity:0.3;
}
</style>
以及
<div class = c1 id = myDiv ></div>
以及
<script>
function cssFn()
{
document.getElementById( myDiv ).style.opacity = 0.8;
}
cssFn();
</script>
Thus i changed the opacity of the element using javascript.. My question is this.Is it possible to make the style declaration done using javascript to be inactive 以及 that declared in class to be active using javascript..I dont need
document.getElementById( myDiv ).style.opacity = 0.3;
我只需要一部与使用风格表格宣布的风格相仿的法典。