navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

Background image and drop shadow

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> Cascading Style Sheets >> Background image and drop shadow
Page: [1]
 
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
Background image and drop shadow - 3/24/2006 7:04:03   
I'm in the early stages of working at the moment on a site that I'm wanting to use a background image with a drop shadow as a background for (the image would just be a plain "box" with a drop shadow on the right and bottom). My problem is that it's likely that not all of the pages will be the same length so if I made the background image say 750 x 1200, on some pages it would be too long, and on others too short and the text would overspill the background image.

Because of recycling images/using cached images etc. I didn't really want to have to specify a seperate image for each page. The only way I could think of to get round it would be to use a seperate image for different portions of the page, but I couldn't figure out how that would work because I'd still need multiple images potentially.

Thoughts? Suggestions?

(No code/url as yet - this is just a theoretical "can this be done?" at this stage)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)
Donkey

 

Posts: 3842
Joined: 11/13/2001
From: Blackfield United Kingdom
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 7:33:35   
How about 3 divs one atop the other.

The bottom one stays a fixed height and uses a fixed background image of the bottom of the box and the bottom shadow.

The top one stays a fixed height and uses a fixed background image of the top of the box showing the shadow slightly offset from the top.

The middle one is variable height and uses a thin "cross section" image set to repeat vertically.

You might have to put the three into a container div to get it to work, and I'm not sure about the code without playing with it for several days but I imagine there is a way to do it.

_____________________________

:)

I have a higher and grander standard of principle than George Washington. He could not lie; I can, but I won't.
Samuel Clemens

(in reply to womble)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 8:54:47   
Ah Donkey! I think you may be onto something there!
Like I said, nothing on screen yet, but I'm thinking with what I'm planning the page would naturally divide into three anyway, so that may work.

Oh if only I had a brain I would indeed be a menace to society! :)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to Donkey)
Tailslide

 

Posts: 5915
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 9:35:41   
quote:

ORIGINAL: Donkey

How about 3 divs one atop the other.

The bottom one stays a fixed height and uses a fixed background image of the bottom of the box and the bottom shadow.

The top one stays a fixed height and uses a fixed background image of the top of the box showing the shadow slightly offset from the top.

The middle one is variable height and uses a thin "cross section" image set to repeat vertically.

You might have to put the three into a container div to get it to work, and I'm not sure about the code without playing with it for several days but I imagine there is a way to do it.


This is more or less what I do on my current site.

_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to Donkey)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 10:52:26   
/makes mental note to self - "Before asking dumb questions on OF check out Tail's site to see how she's done it first"

:)

:)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to Tailslide)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 11:39:58   
quote:

quote:

ORIGINAL: Donkey

How about 3 divs one atop the other.

The bottom one stays a fixed height and uses a fixed background image of the bottom of the box and the bottom shadow.

The top one stays a fixed height and uses a fixed background image of the top of the box showing the shadow slightly offset from the top.

The middle one is variable height and uses a thin "cross section" image set to repeat vertically.

You might have to put the three into a container div to get it to work, and I'm not sure about the code without playing with it for several days but I imagine there is a way to do it.


Soooooooo confused :)! excuse my ignorance or just completely stupidity. BUT could someone explain that again, please? this is exactly what I want to do, I was just going to make 2 images in Photoshop and slap them in a div, but Tail's site is soo nice.:)

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to womble)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 11:50:33   
It's like dividing your rectangular image (assuming your page is rectangular) into three bits.

Top div has a background image of the top part of the image you want to use and is a fixed height, i.e. the 'box' and some of the drop shadow on the right hand side.

For the middle bit you take a small slice of the image (which in my case would be a rectangular white 'box' with the drop shadow on the right) and set the background on the middle div to repeat. The image need only be a few pixels wide - then you just repeat it vertically. Because it's not a fixed height, as you add more content, the div expands to hold all the content and becuase you've set the background image to repeat, as more content's in there, you ger more repeats of the background image and so the middle section of the page 'stretches'.

Same as with the top div, your bottom div is a fixed height and is of the bottom of the box complete with the drop shadow on the bottom and right hand side.

Viewed all together they just look like one image.

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to reformed hater)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 12:05:39   
quote:

For the middle bit you take a small slice of the image (which in my case would be a rectangular white 'box' with the drop shadow on the right)

Now I get that. ok well then I guess my question (maybe) is the shadow? in your new project, Womble, are you drawing the shadow/& box w/ shadow somewhere else or is all that done using CSS.

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to womble)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 12:06:34   
OR, if you are inclined towards fluid/flexi/elastic layouts:
flexi-width with images
flexi-width - look ma, no images

I've even seen someone do it using the sliding-doors technique:)

(in reply to womble)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 12:23:10   

quote:

ORIGINAL: spitfire

OR, if you are inclined towards fluid/flexi/elastic layouts:
flexi-width with images
flexi-width - look ma, no images
I've even seen someone do it using the sliding-doors technique:)


That's it simple clean and not a lot of writting!!!!!!! Just perfect for me the lazy guy.:)

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to spitfire)
Tailslide

 

Posts: 5915
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 12:31:40   
quote:

ORIGINAL: womble

/makes mental note to self - "Before asking dumb questions on OF check out Tail's site to see how she's done it first"



:) Yes 'cos I ALWAYS do it right!! It's a lot fiddlier with fluid layouts but it's certainly possible. Sliding doors techniques aside (keep meaning to try that but never get around to it) you can use a similar technique to the rounded corner thing where you use various hooks to attach the corners and the rest is just thin slivers of background image repeated.

_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to womble)
Tailslide

 

Posts: 5915
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 12:40:44   
quote:

ORIGINAL: reformed hater
but Tail's site is soo nice.:)


Very kind - thank you. Feel free to add more compliments (the cheque's in the post).:)

It's actually going - I'm having a complete change in the next few weeks - going to a more fluid layout. Just about halfway through the rebuild.

_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to reformed hater)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 14:55:58   

quote:

ORIGINAL: Tailslide

(the cheque's in the post).:)


You "cheecky" Brits and your wierd language.:) Learn how to spell!:)


_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to Tailslide)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 15:14:09   
Uh, that's weird even in your language. Try Websters:)

(in reply to reformed hater)
Kitka

 

Posts: 2507
Joined: 1/31/2002
From: Australia
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 15:15:38   
quote:

You "cheecky" Brits and your wierd language.


Look who's talking - you can't even use the spell checker! :) :)

_____________________________

Kitka
**It is impossible to make anything foolproof because fools are so ingenious.**


(in reply to reformed hater)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 15:17:58   
"cheecky" could have been a play on words, Kitka. But, somehow, I doubt it :)

(in reply to Kitka)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 15:57:28   
Hey you guys know how the American educational system is... look at our president:)


PS I was just kidding. If I offended I apologize.
:)

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to spitfire)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 15:58:49   
quote:

ORIGINAL: reformed hater

You "cheecky" Brits and your wierd language.:) Learn how to spell!:)


And just who are you calling weird, huh? *sigh* Damned 'mericans - give 'em some independance, and what do they do? Start spelling stuff just how they please, driving on the wrong side of the road and electing a shrub to govern! :)

In answer to your question RH, at the moment I'm using a mixture of graphics and css. I've got two test pages, one that's a graphic where the text isn't likely to overspill so I've done okay with just one graphic, and the other that at the moment's just plain css with no drop shadow (the subject of my query - I thought it was quite a good idea if all the pages kind of looked the same :)). I'd sort of got Donkey's response in the back of my mind somewhere, but unfortunately my brain's not fully functioning at the moment, but now with the appearance of Tail and Spit....oooooh it's all so exciting!

Tail, you are indeed Queen of Cyberspace (I cannot recall the particular instance for which that title was bestowed upon you - there are of course so many instances of your brilliance), but Uncle B! (that's Sir Spitfire to you RH :)) Grpahic-less drop shadows! That's just. Just. Wow! :) I'm going to have a lovely weekend playing! :)

Self Appointed President of the Tailslide Fan Club

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to reformed hater)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 16:04:34   
No excuse RH, the people of Florida votified for him and his brother. Where is it you live now? :)
And Womble dear, I believe your Uncle B can claim authorship of "Queen of Cyberspace" following yet another bit of brilliance from Tail:)

(in reply to reformed hater)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 16:11:50   
Not to mention our voting fiasco in the 2001 election... Florida is where the dumb people come to die.... So who wants to go to Disney?!:)

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to spitfire)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 16:18:11   
quote:

ORIGINAL: reformed hater
I was just kidding. If I offended I apologize.
:)

No offence taken, the Brits (and Kitka) are just indulging in a little Friday leg-pulling. it's a national sport, we aren't much good at any other sport. :)

Hey are there any Brits who would like an invitation to Andrew (Freddie) Flintoff's Benefit bash in May to celebrate a whole 10 years with Leicester Cricket Club. Tables seat 10 people. Executive tables for 」4,000 each (+VAT) and VIP tables for 」6,000 each (+VAT). You also get to buy (private) lottery tickets and bid for tat in an auction. What's all that about, poor old Freddie, running out of cash? :)

(in reply to reformed hater)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 16:29:39   
quote:

ORIGINAL: spitfire
And Womble dear, I believe your Uncle B can claim authorship of "Queen of Cyberspace" following yet another bit of brilliance from Tail:)


You are indeed King of Cyberspace Uncle B :) (even though my dreams of doing "real life" stuff are now fading as I am drawn to a certain recently bookmarked page :):))

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to spitfire)
reformed hater

 

Posts: 167
Joined: 2/1/2006
From: The land of sun and hurricanes; US
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 16:54:10   
quote:

It's actually going - I'm having a complete change in the next few weeks - going to a more fluid layout. Just about halfway through the rebuild.

Can't wait to see what it is...
God save the "queen":)

_____________________________

When asked what the White House was like by a British student George W. Bush responded 的t is White"

(in reply to womble)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/24/2006 17:11:03   

quote:

ORIGINAL: reformed hater
God save the "queen":)

Sung to the tune of My country 'tis of thee, I suppose:)

(in reply to reformed hater)
Tailslide

 

Posts: 5915
Joined: 5/10/2005
From: Out here on the raggedy edge
Status: offline

 
RE: Background image and drop shadow - 3/25/2006 8:34:56   
quote:

ORIGINAL: spitfire
following yet another bit of brilliance from Tail:)


Oh oh - what'd I say?


_____________________________

"My strategy is so simple an idiot could have devised it"
Little Blue Plane Web Design | Blood, Sweat & Rust - A Land Rover restoration project

(in reply to spitfire)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/25/2006 8:54:20   
probably something about doctypes :):)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to Tailslide)
spitfire

 

Posts: 424
Joined: 8/6/2005
Status: offline

 
RE: Background image and drop shadow - 3/25/2006 9:16:23   

quote:

ORIGINAL: Tailslide
Oh oh - what'd I say?

Nothing toooo controversial, petal. But we haven't seen your re-designed logo yet:)

(in reply to Tailslide)
womble

 

Posts: 5461
Joined: 3/14/2005
From: Living on the edge
Status: offline

 
RE: Background image and drop shadow - 3/25/2006 9:21:41   
:)

_____________________________

~~ "A cruel god ain't no god at all" ~~
:)

(in reply to spitfire)
Page:   [1]

All Forums >> Web Development >> Cascading Style Sheets >> Background image and drop shadow
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts