Linking <img> is easy. It is almost the same as text linking. Simply replace the text in between the start <a> and </a> tag with the source of the image.
Example
<a href=“index.html"><img src=“logo.jpg” alt=“logo” /></a>
<!DOCTYPE html>
<html>
<head>
<title>Scholars Image Hyperlink Example</title>
</head>
<body>
<p>Click following link</p>
<a href="http://scholarsglobe.com">
<img src="logo.jpg" alt="logo"/>
</a>
</body>
</html>
<a href=“index.html"><img src=“logo.jpg” alt=“logo” /></a>
<!DOCTYPE html>
<html>
<head>
<title>Scholars Image Hyperlink Example</title>
</head>
<body>
<p>Click following link</p>
<a href="http://scholarsglobe.com">
<img src="logo.jpg" alt="logo"/>
</a>
</body>
</html>
Result:
Copy and Paste Code to Notepad and save as index.html and open with any web browser, or use editors like Dreamweaver or Frontpage to see results.
No comments:
Post a comment