HTML Help
Please
Search
for the answer to your question before asking it! Thanks.
How to make a Button act as a Link
Post a Reply to this Topic
Ask a New Question
Click here to go to the original topic
HTML Help Forum
->
General HTML
View previous topic
::
View next topic
Author
Message
dwills
Joined: 15 Jun 2004
Posts: 2
Posted: Tue Jun 15, 2004 8:38 pm
How to make a Button act as a Link
I hope this is a simple question. I would like a button to act as an <A HREF> . In other words, the button:
<button type button>Slide Show</button>
when pressed, would take the viewer to another page, just like:
<A HREF="./slideshow.html">Slide Show</A>
would behave if you clicked on the 'Slide Show' link. How can I "combine" the two (so to speak)?
mjpliv
Joined: 11 May 2004
Posts: 402
Location: Nova Scotia
Posted: Wed Jun 16, 2004 2:48 am
Have a look at this link, it shows how to use onclick to redirect to another page when the button is clicked using java.
http://www.javascriptkit.com/howto/button2.shtml
And for those that don't want to read the whole page here is their example -
Code: <button style="width:65;height:65" onClick="window.location='http://www.whateverpage.com'"><b>Home</b></button>
dwills
Joined: 15 Jun 2004
Posts: 2
Posted: Wed Jun 16, 2004 5:36 pm
That code worked perfectly! Thanks.
DARFUR
Get a
Stop the Genocide
poster at
SaveDarfur.org
.
Also see
Eyes on Darfur
.
HOSTING / DESIGN
$1.99 Domain Registration
Cheap Web Hosting
Website Templates
MAKE MONEY
Sell Domain Names
Sell Website Templates
Your Ad Here
HTML Help Forum
->
General HTML
Page
1
of
1
Powered by phpBB Search Engine Indexer
Powered by phpBB 2.0.19 © 2001, 2002 phpBB Group