SQL PHP HTML ASP JavaScript articles and free scripts to download

Linking pages using buttons

Hyper links are used to link different pages within a site and outside a site to each other. Same thing can be achieved by using a button. We can use a button to link different pages. We will connect the url of the new page to the onclick event of the button. We can do this by using a form and a submit button but there is no point in using a form for a hyper linking of pages. So here are some examples of using buttons to link different pages.

<input type=button onClick="parent.location='index.html'" value='click here'>

Another way of linking button

<input type=button onClick="location.href='index.html'" value='click here'>

Demo of two types of buttons with code

<input type=button onClick="location.href='../'" value='click here to visit home page'>


<input type=button onClick="parent.location='http://www.plus2net.com/'" value='click here to visit home page'>

Some time from SEO angle linking using a button is not a good idea as we loose the anchored text advantage of hyper linking. Read the article on search engine friendly page design to know more on this.
Please rate this Article on one to five scale



rozel rosauro22-03-2012
it is very helpful to me
...thanks
salabha04-04-2012
Thank u very much..itz working...
Rosneil Mananquil29-04-2012
Nice. This is a good tutorial. Thanks.
N G Sundar14-05-2012
Exactly what I wanted. Did not want to submit the form; instead wanted to go to another page.
rozel rosauro05-06-2012
it is very helpful to me
...thanks
www.marswebsolution.com12-06-2012
Exactly what I wanted. Did not want to submit the form; instead wanted to go to another page. it is very helpful to me
...thanks
chavda bhavna07-08-2012
nice understanding exampels.good.thanks.
ashish21-08-2012
yes, did great help. thanks
DekeR19-09-2012
very helpfull - just ask google, and dont need read API or something like that, THX
harini26-12-2012
Amazing article.. thanks for the help.
sanju07-01-2013
how i can open a folder from pc by clicking button and change photo by selecting any photo
venkat15-03-2013
very useful ....
Post Comment This is for short comments only. Use the forum for more discussions.
Name
Email( not to be displayed)Privacy Policy
1+2=This is to prevent automatic submission by spammers. Please enter the result of the sum as asked

Join Our Email List
Email:  
For Email Newsletters you can trust
HTML . MySQL. PHP. JavaScript. ASP. Photoshop. Articles. FORUM Contact us

©2000-2013 plus2net.com All rights reserved worldwide Privacy Policy Disclaimer