hello guys I'm trying to make a Multipage form in java script but keep receiving the error Uncaught TypeError: Cannot read property 'style' of null; I've searched and found answers but to no avail.... it seems to work fine until I implement the show element function later in the code.
<script type="text/javascript">
document.write('page'+1)
function hideElement(element)
{
document.getElementById(element).style.display = 'none';
}
function showElement(element)
{
document.getElementById(element).style.display = 'initial';
}
/*function lastPage()
{
hideElement('page'+i-1);
showElement('page'+i);
}
*/
</script>