Use HTML form button to link to another page

Posted by Shek on May 6, 2008 under HTML | Be the First to Comment | Total View: 32,185 views

Editor’s note: In my past posts of HTML form, the attribute “action” of the HTML form is to indicate what page will load and the data of the form will be submitted. To use the same concept, we could also use the submit button to play a role in the directing to another page. All we have to do is to create a form with just a submit button in it. Here is an example:

1
2
3
4
5
6
<html>
<form action="http://www.phpsuperblog.com" name="form1">
<INPUT type="submit" value="link to another page"/>
</form>
 
</html>

By pressing the button below will direct you to the home page of www.phpsuperblog.com:

Not what you want? Try a Search

Add A Comment

*