View Full Version : HTML: inline image & borders/border-width

02-09-2012, 07:48 AM
hi, i'm new to html and have a question. any help would be much appreciated.

my book says setting an inline image as a link will make it have a border.

i'm supposed to set some images as links and then modify the border-widths.

i think i did this right (clicking each picture leads to the right destination)

the problem is that although they're links, the pictures don't seem to have a border around them (actually, as per the instructions, i set all but one of the pictures' border-widths to 0, but even before i did that no border showed)

i tried making the border bigger, but that did nothing

since the images function as hyperlinks as intended, my question is what is wrong about my code that made it so borders did not show up?

<img src="fiddler.jpg" alt="Fiddler on the Roof" />
<hr />

<a href="home.htm"> <img src="home.jpg" alt="home" /></a>


<a href="slide1.htm"> <img src="start.jpg" alt="start" /></a>
<a href="slide1.htm"> <img src="back.jpg" alt="back" /></a>
<a href="slide2.htm"> <img src="forward.jpg" alt="forward" /></a>
<a href="slide6.htm"> <img src="end.jpg" alt="end" /></a>

<br />

<a href="slide1.htm"> <img src="thumb1.jpg" alt="slide1" style="border-width: 5" /></a>
<a href="slide2.htm"> <img src="thumb2.jpg" alt="slide2" style="border-width: 0" /></a>
<a href ="slide3.htm"> <img src="thumb3.jpg" alt="slide3" style="border-width:0" /></a>
<a href="slide4.htm"> <img src="thumb4.jpg" alt="slide4" style="border-width: 0" /></a>
<a href="slide5.htm"> <img src="thumb5.jpg" alt="slide5" style="border-width: 0" /></a>
<a href="slide6.htm"> <img src="thumb6.jpg" alt="slide6" style="border-width: 0" /></a>
here's a link: http://jritt.brinkster.net/tutorial2/case2/slide1.htm

02-09-2012, 07:59 AM
Set a color and style to the border, like boder:5px solid red;