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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Stretching backgrounds vertically to accommodate text in CSS

Status
Not open for further replies.

alexanderdring

Technical User
Dec 27, 2002
36
FR
Hello all,

I am building a relatively straightforward site in XHTML/CSS however the background appears as a white label on which all of the content sits. So I have a thin shadow all the way around the content area (760px x 600px) and rounded corners. I'm keep the top and bottom areas of the label static (the corners), but I was wondering if anyone knew how to stretch or compress the central area, which will have a shadow on each side, without affecting the image quality. Maybe I could produce a very large image (on the vertical axis) and then clip it to fit the text? I would appreciate any help anyone could offer!

Thanks.

Alex.
 
You'll need to construct the "label" with multiple parts.

A top bit, a bottom bit and a bit in the middle that simply repeats vertically.

You'll then need to "hook" these into backgrounds of elements in your site.

You might attach the top graphic to a heading, the middle bit to a div, or paragraph and the bottom to a paragraph called "footer" or something.

You get the idea?

Foamcow Heavy Industries - Web design and ranting
Buy Languedoc wines in the UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top