FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

expanding image for div (rounded corners etc)

 


riv_
Can anyone explain how to make an image that expands and contracts with a div (Using CSS please, I'm not interested in using tables!) I can easily do it with a fixed height, but I want to make use a background image that expands vertically also.
Can someone explain how, or point me to the place that explains it? THanks very much!
Scanner771
you could try flash, if you dont know flash you can do it in AfterEffects its a lot easier to use and export as a flash file.
dkbg
Well, you should use background images in CSS. You may have to add some extra markup depending on the situation. If you're making something like this you won't have to add extra markup because you can apply the backgrounds to the p or h2:

Code:
<div class="box">
<h2>Title</h2>
<p>Here is some text.</p>
</div>


So the CSS would be:

Code:
.box { background: #fff url(rounded-top.png) no-repeat scroll top left; }
.box p { background: #fff url(rounded-bottom.png) no-repeat scroll bottom left; }


Plus some sizing and such. Here is a tutorial on rounded corners in CSS. Try searching Google as well, its always a good place to try.
Reply to topic    Frihost Forum Index -> Webmaster and Internet -> Design Tips

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.