Link to home
Start Free TrialLog in
Avatar of shantelechy
shantelechyFlag for Canada

asked on

CSS Background overflow

Can a CSS background be defined to overflow it's container? How? Thanks :)
ASKER CERTIFIED SOLUTION
Avatar of GrandSchtroumpf
GrandSchtroumpf

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Daydreams
Daydreams

What about overflow: visible;

http://www.w3schools.com/css/pr_pos_overflow.asp

"The content is not clipped. It renders outside the element"

Yes, it can overflow.
Grand is right.. background does not seem to overflow, but content does if the value is "visible"
Avatar of shantelechy

ASKER

Thank you, so the solution appears to be make the image 'content' and position the text to appear on top.
yes, that's a possible solution.
another solution is to set the size of your container, but it has its incovenients too.
the basic idea is to separate content from presentation.
if your image is part of the content (like the image of your product), then place it in the html.
if it's presentation (like a rounded border effect), then place it in the CSS.