i have the following code on a page (this is a simplified version):
[code=html]<div id=”rotate_div”><a href=”page.html”><img src=”button_rotate.jpg”></a></div>
the CSS:
[code]#rotate_div {
position:relative;
float:right;
}
#rotate_div a img {
width:53px;
height:20px;
border:1px solid #333;
}
but i need to apply this ID to several divs… so i thought that it would be simple enough…
i tried this:
[code=html]<div class=”rotate_div”><a href=”page.html”><img src=”button_rotate.jpg” class=”rotate_image”></a></div>
CSS:
[code].rotate_div {
position:relative;
float:right;
}
.rotate_image {
width:53px;
height:20px;
border:1px solid #333;
}
(this is probably wrong for obvious reasons, but i don’t understand why).
anyway, when i change the thing to CLASSES, the image (button_rotate.jpg) is stretched to the size of it’s parent div (305x350px) but i’m not sure why.
i’m sure it’s something to do with position:relative/absolute; though. just a guess.
here a link to the page this is on (using several IDs, which is incorrect syntax) – but it’s really complex and annoying to look at.
[url]http://www.foremostgroups.com/dev/2007corporate/K&B/heritage_bath/delaware.shtml
and the one with the classes applied:
[url]http://www.foremostgroups.com/dev/2007corporate/K&B/heritage_bath/delaware2.shtml
thanks in advance for any help/ideas.