This text (with id "olddata") represents data that can be hidden. A button hides it by setting its display style to "none". The button then redisplays it by setting its display style to "block".

This text represents new data that's always visible.


Here's the HTML button definition:
<button name="ShowOldData" id="button1" class="smallbutton" onclick="
    if (button1.value == 'Show Old Data') {
        // When the button says 'Show old data', expose the data and change the button value
        olddata.style.display='block';
        button1.value='Hide Old Data';
    } else {
        // When the button says 'Hide old data', do just that (and change the button value)
        olddata.style.display='none';
        button1.value='Show Old Data';
    }">
Hide Old Data</button>



10/11/2007 Robin.Richmond@tri-c.edu
Back to the ITWM1010 home page