Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

link

Status
Not open for further replies.

Cullen411

Programmer
Aug 17, 2005
89
GB
Is it possible to make this image as a link?

#banner {
width:500px;
height: 60px;
margin: 0 auto;
background: #fff url(/images/brandlogo.gif) top left no-repeat;
text-align: right;
padding:0 0 0 280px;
}

couple of other issues, if a page has lots of container div's should I use the IE content width fix for each container? I would suspect that using the fix would be the right way to go?
is there any sites that will simulate all the browsers such as IE 5?
 
Where is an image? You could add display: block; and apply the banner id to an anchor element. That way it is what you want and it is a link.

I suppose you're talking about IE5.* box model misinterpretation. For most part, you should try and produce code that doesn't rely too much on hacks. Also, know that IE6 has a correct box model and since there are less and less IE5s out there, you might think about it.
 
Is it possible to make this image as a link?
Certainly:
Code:
<div id="banner" onclick="this.location='[URL unfurl="true"]http://www.google.com';">...</div>[/URL]
That is one way. You'll have to be more specific about exactly what you want I think.
...the IE content width fix for each container
I can't see any reason why you should need to do this. If you are experiencing a problem... let us know... but I would suggest you choose a valid DOCTYPE and make sure you are not in quirks mode (and that your code validates) -- if you experience symptoms of this "IE content width" problem... then by all means implement... but I have never used this and would not recommend it wholesale.

Cheers,
Jeff


[tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch
[/tt]
 
Sorry, what I mean is making the background image a link

#banner {
width:500px;
height: 60px;
margin: 0 auto;
background: #fff url(/images/brandlogo.gif) top left no-repeat;
text-align: right;
padding:0 0 0 280px;
}
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top