Look-Ma-No-Hands HTML Tricks : Link Button

Updated on : 02-02-2002
No Java, no plugins, no nothing. Just a simple and stunningly useless HTML trick. It may even not always work depending on the kind/version of the browser you use. But what do I care?!

A link to any specific page can be designated in a number of ways. The most straightforward way of doing that would look something like this:

Peer-to-peer File Sharing

How's this for a change? A simple button that takes the visitor to the linked page when pressed.

This is how it's written:

<form method="LINK" action="cjftplist.html" target="results">
<input type="submit" value="Peer-to-peer File Sharing">
</form>

Note that [target="results"] is optional. It depends on how you want the linked page targeted/displayed and should vary accordingly. For example, [target="_blank"] will pop-open a new separate sheet and display the linked page there. You can opt for [target="_top"] , [target="_parent"] , and [target="_self"] . Try them all and find out for yourself what they do. To be honest, I don't remember which does what.

Let's make up, just for the hell of it, a button that is linked to, ah, OK, CNN. Pretty exciting, huh?

Here's how it's written

<form method="LINK" action="http://www.cnn.com/" >
<input type="submit" value="Go to CNN"> </form>