PDA

View Full Version : "Double-layer" background with CSS...


Joonas
07-13-2005, 06:25 AM
Okay, the solution to the next issue, if you can call it an issue, is most likely so simple that I was just blind to it, but anyway: I have a background image for the web site, defined in the CSS script for the whole body. Now is there a sensible way to add a secondary image on top the previous image? Without editing the original background image. In a non-ideal example there would be a landscape as the original background, then one would be adding a sun on to it, but straight from the source code, not editing the image.

Body code so far:

body
{
background: url(http://img90.exs.cx/img90/5007/49-clouds.jpg) no-repeat;
background-color: #E8EFF6;
margin: 0;
padding: 10px 5px;
font: x-small Georgia,Serif;
text-align: center;
color: #222222;
font-size: small;
}

Fraeon Waser Duhni
07-13-2005, 07:21 AM
[Obi-wan] Use the Z-index, Joonas. [/Obi-wan]

zilppuri
07-13-2005, 02:10 PM
Why not add <table class="something"> on top of it with size of 100% x 100%?
then just put rest of the page inside <td>.

then use the CSS code:
table.something {
background: transparent url("sun.gif");
}

with the sun.gif being the sun with transparency. PNG works too with transparency, but not in IE I think.

I hope I understood correctly and this is what you were looking for.

Joonas
07-13-2005, 02:14 PM
D'oh!

rg3
07-13-2005, 02:23 PM
Or the same using divs...

NetNessie
07-13-2005, 09:36 PM
zilppuri said:
Why not add <table class="something"> on top of it with size of 100% x 100%?
then just put rest of the page inside <td>.



Bad zilppuri, bad. Dont do that.

Usurper
07-13-2005, 10:08 PM
Fraeon Waser Duhni said:
[Obi-wan] Use the Z-index, Joonas. [/Obi-wan]



The truth Fraeon speaks. Using tables for layout, to the dark side this leads.

zilppuri
07-14-2005, 05:11 AM
NetNessie said:

zilppuri said:
Why not add <table class="something"> on top of it with size of 100% x 100%?
then just put rest of the page inside <td>.



Bad zilppuri, bad. Dont do that.



huh.. why?

Fraeon Waser Duhni
07-14-2005, 05:23 AM
zilppuri said:

NetNessie said:

zilppuri said:
Why not add <table class="something"> on top of it with size of 100% x 100%?
then just put rest of the page inside <td>.



Bad zilppuri, bad. Dont do that.



huh.. why?



http://www.hotdesign.com/seybold/

http://forums.3drealms.com/ubbthreads/images/graemlins/eek.gif

Joonas
07-15-2005, 06:35 AM
Fraeon Waser Duhni said:

zilppuri said:

NetNessie said:

zilppuri said:
Why not add <table class="something"> on top of it with size of 100% x 100%?
then just put rest of the page inside <td>.



Bad zilppuri, bad. Dont do that.



huh.. why?



http://www.hotdesign.com/seybold/

http://forums.3drealms.com/ubbthreads/images/graemlins/eek.gif



That what... ... great.

mouth
07-15-2005, 12:33 PM
hey, isn't this site created by using tables and cells?

Fraeon Waser Duhni
07-15-2005, 07:08 PM
mouth said:
hey, isn't this site created by using tables and cells?



Yes, and that's why Joe will go to a special 10th level of hell where they punish people who use javascript and nested tables. http://forums.3drealms.com/ubbthreads/images/graemlins/wink.gif

NetNessie
07-16-2005, 03:48 AM
mouth said:
hey, isn't this site created by using tables and cells?



Yes, but the fact that its 3Drealms cancels out the fact that this website isnt complaint. http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif

ADM
07-16-2005, 05:44 AM
mouth said:
hey, isn't this site created by using tables and cells?



Most message boards use tables and cells and the like mainly because CSS isn't too advanced at the moment to code a full site replicating a table design without causing problems with older browsers.

Give it time and you will see alot of forum software switching over to CSS driven designs. It's just so much more simpler, faster and easier to control.

Coupled with PHP and you have heaven, yes I realise I sound like a major geek right now but it's true http://forums.3drealms.com/ubbthreads/images/graemlins/tongue.gif

I love playing around with CSS.. In the next couple of months I will have a design up on csszengarden.com -- mark my words http://forums.3drealms.com/ubbthreads/images/graemlins/tongue.gif

NetNessie
07-16-2005, 11:44 PM
ADoomedMarine said:

mouth said:
hey, isn't this site created by using tables and cells?



Most message boards use tables and cells and the like mainly because CSS isn't too advanced at the moment to code a full site replicating a table design without causing problems with older browsers.



I believe the opposite, CSS would easily be able to replace the tables system of forum software, but your right about browser compadibility, which may cause issues.

biXen
07-17-2005, 07:06 AM
Mattze did a good job on PayneReactor, taking it from tables to fully CSS and layerbased. But it's hard. I'm doing more layerstuff nowadays, but changing my ways completely is hard.

Anyway Joonas... for the love of god, don't put all that shit in the body tag http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif

And for people that truly want to learn CSS I recommend doing a view source at mozilla.org and getting the stylesheets as well... was interesting for me http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif

Rider
07-18-2005, 04:40 AM
this is the last time I check out a thread about website designing http://forums.3drealms.com/ubbthreads/images/graemlins/redface.gif

the pineapplehead
07-18-2005, 01:50 PM
Check out csscreator.com

Tony, the guy who runs it, converted it all to a CSS based layout.

NetNessie
07-20-2005, 01:20 AM
Rider said:
this is the last time I check out a thread about website designing http://forums.3drealms.com/ubbthreads/images/graemlins/redface.gif



Its not that hard, http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif