Admin Admin
Posts : 44 Points : 129 Reputation : 0 Join date : 2011-05-16 Age : 33 Location : Philppines
| Subject: Hyperlink the Image Tue May 31, 2011 11:24 am | |
| This example is exactly the same as the previous example, except that this time we're linking the images to another website. When we click on each picture, a new window will open with the web page as specified in our HTML code. To do this, we simply surround the picture code with an HTML anchor tag (or 'a' tag) to create a hyperlink. I've also removed the border (using border="0"). Borders tend to be created automatically when you hyperlink an image in HTML. HTML Code: - Code:
-
<!-- Codes by Quackit.com --> <div style="height:221px;width:330px;overflow:scroll;"> <a href="http://www.natural-environment.com/places/milford_sound.php" target="_blank"><img src="http://i516.photobucket.com/albums/u323/natural_pics/milford_sound.jpg" border="0" width="330" height="221" alt="Sample picture for scroll box: Milford Sound, New Zealand" /></a><br /> <a href="http://www.natural-environment.com/places/franz_josef_glacier.php" target="_blank"><img src="http://i516.photobucket.com/albums/u323/natural_pics/franz_josef_glacier2.jpg" border="0" width="330" height="221" alt="Sample picture for scroll box: Franz Josef Glacier, New Zealand" /></a> </div> <p style="font-family:verdana,arial,sans-serif;font-size:10px;"><a href="http://www.quackit.com/html/codes/">HTML Codes</a></p>
live preview : http://junilstyle.ucoz.net/junilstyle12/4.html |
|