Web development by PHP-Web-Host.com   Website Hosting by PHP-Web-Host.com
Web Hosting by PHP-Web-Host.com

HTML Tutor!

HTML Tutor, learn to author your own website

 

 

Resources

SoftSmart.co.za | Linux Web Hosting

 

 

Please sign up for our Free News Letter
Please help us by taking this 1 minute survey!

FAQ: My image links have these little blue dashes next to them. Also I keep getting spaces between them and I want them to be flush up against each other. I don't understand... it works right in Browser B.

Home Email Links

A: Most browsers interpret a carriage return between images as a space. A few browsers don't. It's that simple. The little blue dash (seen in some browsers) is simply the link underlining an empty space. The cure is to eliminate carriage returns right before or right after the image.

This is the markup for the above images:

<p align="center">
<a href="myhome.php">
<img src="myhome.gif"
     width="66" height="23"
     border="0" alt="Home">
</a>
<a href="mailto:[email protected]">
<img src="myemail.gif"
     width="66" height="23"
     border="0" alt="Email">
</a>
<a href="mylinks.php">
<img src="mylinks.gif"
     width="66" height="23"
     border="0" alt="Links">
</a>
</p>

If we were to change it to this we would eliminate the little blue dashes:

<p align="center">
<a href="myhome.php"><img
     src="myhome.gif"
     width="66" height="23"
     border="0" alt="Home"></a>
<a href="mailto:[email protected]"><img
     src="myemail.gif"
     width="66" height="23"
     border="0" alt="Email"></a>
<a href="mylinks.php"><img
     src="mylinks.gif"
     width="66" height="23"
     border="0" alt="Links"></a>
</p>

Home Email Links

Another adjustment and the spaces disappear too:

<p align="center">
<a href="myhome.php"><img
     src="myhome.gif"
     width="66" height="23"
     border="0" alt="Home"></a><a
   href="mailto:[email protected]"><img
     src="myemail.gif"
     width="66" height="23"
     border="0" alt="Email"></a><a
   href="mylinks.php"><img
     src="mylinks.gif"
     width="66" height="23"
     border="0" alt="Links"></a>
</p>

HomeEmailLinks

Take the time to understand what's going on in the above examples.

Is this a pain in the butt? Only if you don't understand what's happening and how to fix it. Is Browser A a crappy browser? Not necessarily, it's just different than Browser B. Browsers sometimes do different things with the same markup.


Another way to link is to link not just to a page, but to a specific part of a page. Click here to be magically transported to where we first talked about URLs. Since it would be kind of hard to have you build an example, I'll just do the best I can to explain how it's done.

First start with the spot you want people to be transported to. Pick a word and wrap it in the <a> tags.

<a>Add</a> the URL and you're done!

Next give that spot a name...

<a name="upabit">Add</a> the URL and you're done!

What you have done is marked that spot. Now that spot can be referenced and linked to.


Start building the link...

Click <a>here</a> to be magically transported...

Add the URL of the document to be referenced...

Click <a href="lesson12.php">here</a> to be magically transported...

And lastly, add the anchor name like so...

Click <a href="lesson12.php#upabit">here</a> to be magically transported...

And that's all there is to it! Not exactly brain surgery is it??

So, you want to make a Web Page!
Lessons: Intro 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26
Index & Quick Reference      Table of Contents      ColorPicker      BareBones HTML Guide
Color Charts      Simple Font Widget      Practice Exercises      Where are my images?
Print version of this tutorial available - Get the PageTutor Book & CD

 

 

SoftSmart.co.za | Linux Web Hosting

 

 

Please sign up for our Free News Letter
Please help us by taking this 1 minute survey!

 

 

We accept PayPal

 

Web Hosting by PHP-Web-Host.com Website Hosting by PHP-Web-Host.com

[ Home ] | [ Software ] | [ Web Development ] | [ Resources ] | [ Contact ] | [ Privacy Policy ] | [ Acceptable Use Policy ] | [ Terms of Service ] | [ Sitemap ] | [ Clients ] | [ Affiliates ]

[ PHP Web Hosting ] | [ Linux Web Hosting ] | [ 500mb PHP Web Hosting ] | [ 1Gb PHP Web Hosting ] | [ 3Gb PHP Web Hosting ] | [ 6Gb PHP Web Hosting ] | [ 10Gb PHP Web Hosting ]

[ HTML Tutor ] | [ CSS Tutorial ] |