Page 1 of 1

to go to next page on click

Posted: Tue Aug 03, 2004 3:42 am
by bugthefixer
how can i make a page to go to next on clicking a button which is not a submit button.

Posted: Tue Aug 03, 2004 5:22 am
by kettle_drum
Ummm, not sure if this syntax is correct but:

Code: Select all

<input type="button" value="Next Page" onClick="window.location=page2.php">

Posted: Tue Aug 03, 2004 6:04 am
by fresh
wrong..

it's document.location='myphp.php'..

but you were pretty close ;)

Posted: Tue Aug 03, 2004 6:54 am
by qads
both work actually :P

Posted: Tue Aug 03, 2004 10:08 am
by kevin7
hmm... i'm usually using...

Code: Select all

<input type="button" value="Next Page" onClick="window.navigate('page2.php')">