Suppose I have some text within <div id=”div1″></div> tags, it’s easy to display and hide this block of text with the help of some Javascript code and CSS.
To hide the block of text, do the following:
<script language=”javascript”>
document.getElementById(’div1′).style.display = ‘none’;
</script>
To display the block of text, just remove the word ‘none’ from the code above as follows:
<script [...]
Filed under: CSS, Javascript, Tutorials and Tricks | No Comments »









