Code:
<script language="javascript">
function xyz(){
document.getElementById('st').style.color = 'red';
document.getElementById('st').style.fontSize = 50;
}
</script>
<p id="st">We are leaning how to style web page using JavaSCript</p>
<input type="button" value="style" onClick="xyz()" />
Comments
Post a Comment