Why is my image not becoming hyperlinked? Here's my HTML code (with links taken out), and the CSS of the div it's in:
<div class=bannercontainer>
<a href="(working URL here)" target="_blank"><img src="image.png" width="194" height="67" border="0" /></a></div>
.bannercontainer{ margin-left: auto; margin-right:开发者_JAVA技巧auto; width:900px; height:500px; margin-top:50px;}
<div class=bannercontainer>
needs quotes like this
<div class='bannercontainer'>
Adding "clear:both" to .lowerpart
is a solution, of sorts. But I'd recommend re-writing your HTML. It doesn't need to be so complicated... or filled with errors :-/
Note: #feature
should be a class (.feature
), not an ID, as there's many of them in the document.
Tip: Trying verifying your HTML in the future: http://validator.w3.org/
Also maybe getting a book on learning HTML (Headfirst HTML/CSS couldn't make it much easier) or doing some online training: http://www.w3schools.com/html/default.asp
精彩评论