Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
div opacity with fixed bg
Old 03-21-2008, 02:27 PM div opacity with fixed bg
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
Need some help, or get pointed in the right direction.

Goal: Have a fixed bg image placed behind a 3 column css layout, with the middle divs' to display 25% of background through it.

Problem: The middle div's have text and images within them. Don't want the parent div's attributes to carry over the opacity to the images held within the div.
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
 
Register now for full access!
Old 03-21-2008, 05:58 PM Re: div opacity with fixed bg
vangogh's Avatar
Post Impressionist

Latest Blog Post:
Why Responsive Design?
Posts: 10,815
Name: Steven Bradley
Location: Boulder, Colorado
Trades: 0
Unfortunately at the moment the parent's transparency gets inherited by the child elements. It kind of makes transparency much less useful than it could be so hopefully soon we'll be able to overwrite the transparency for the child divs.

I have no idea if this will work, but I'll get creative. Would it be possible to set that middle div to background: transparent so everything shows through. Then directly behind that div place another div that is only the background color and transparency you want.

So someone looking at the page sees your div with the text and images and since the background on that div is transparent sees behind it to another div which mimics the top div in size, but has a semi-transparent background that allows you to see the fixed image behind everything.

Again I'm not sure if that would work for your layout and even if it does it might not be worth the time to code it, but it might be a creative way to get what you want.
__________________
l Search Engine Friendly Web Design |
Please login or register to view this content. Registration is FREE

l Tips On Marketing, SEO, Design, and Development |
Please login or register to view this content. Registration is FREE

l
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
vangogh is offline
Reply With Quote
View Public Profile Visit vangogh's homepage!
 
Old 03-21-2008, 08:55 PM Re: div opacity with fixed bg
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
sounds a little over my shoulders but it's an idea.
I'd have a heck of a time getting the div behind the content div to be the same size. I have a series of divs with spacing between them. So I would even need some parts to show 100% of the background image through.
Kind of tough.
There's no hack out there to let the "child" divs disregard the transparent attribute of the main, "parent" div?
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
Old 03-22-2008, 05:04 PM Re: div opacity with fixed bg
ironspyder's Avatar
Novice Talker

Posts: 5
Name: Kinley
Location: Indiana
Trades: 0
Couldn't you make a second background image for your div, copy of the original with the desired visual effect, and then apply it with attachment fixed, and position 0,0? This will give the illusion of transparency without making your div transparent at all.

Got the idea from this guy
http://meyerweb.com/eric/css/edge/co...iral/demo.html
ironspyder is offline
Reply With Quote
View Public Profile
 
Old 03-23-2008, 02:13 PM Re: div opacity with fixed bg
MattCoops's Avatar
Ultra Talker

Posts: 423
Name: Matt Cupan
Location: Charlotte, NC
Trades: 0
I guess I could break up the image into different ones for each div, photoshop an opacity, and keep a fixed bg of the whole image in the bg.
Sounds like unneeded bandwith, but desired look achieveable.
****. Does CSS3 offer opacity to the parent div without disrupting images and child divs?
__________________
Matt - Tweeting
Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

read my
Please login or register to view this content. Registration is FREE
MattCoops is offline
Reply With Quote
View Public Profile Visit MattCoops's homepage!
 
Reply     « Reply to div opacity with fixed bg
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.54729 seconds with 12 queries