Solved

Vertical shadows on table or div...

Posted on 2004-10-03
6
434 Views
Last Modified: 2011-10-03
I have seen a lot of posts about drop shadows for tables and div, however, I haven't seen anything specific to what I am looking for.  I am wanting vertical shadows running down the sides of a centered table or div.  Here is a site that has an example of what I need: http://www.squidfingers.com

Notice that it is a gradient shadow, not just a block of color.  I have my suspicions that that particular site uses an image that just gets centered, but I would like to know if it is possible to do with javaScript or some other web language.  Thanks.
0
Comment
Question by:kearnguy
  • 3
  • 2
6 Comments
 
LVL 49

Assisted Solution

by:Roonaan
Roonaan earned 50 total points
ID: 12215311
IE only, you could look for some css filters and adjust them...
http://www.fred.net/dhark/demos/css/css_filter_examples.html

But using a plain image would be easier.

-r-
0
 
LVL 3

Accepted Solution

by:
OutsideTheBox earned 200 total points
ID: 12216766
Hi kearnguy,

Your suspicions are pretty much right.

The way it was done the example site (squid fingers) was like this:

They created a gif in Photoshop that became this:

http://www.squidfingers.com/images/bkgd_body.gif

Then they caused this to be part of the body background with some css styling :

http://www.squidfingers.com/includes/css/style.css

body {
      font-family: verdana,sans-serif;
      font-size: 11px;
      color: #785A3C;
      background-color: #785A3C;
      background-image: url(/images/bkgd_body.gif);
      background-repeat: repeat-y;
      background-position: center;
      text-align: center;
      margin: 0 auto 0 auto;
      padding: 0;
}

This styling tells the viewer's browser to center this gif on the background, then repeat it all the way to the bottom (repeat-y) and it looks like one solid picture.

Then the div was centered inside.

It is pretty easy doing it this way. Are you just after this styling or is there some dynamic functionality reason you want to use JavaScript to accomplish this?

Cheers!
0
 

Author Comment

by:kearnguy
ID: 12219597
OutsideTheBox,

No, I don't need any dynamic functionality.  I think what you have said will work...I am trying it out now.  I will get back to you once I have tested it.

Thanks again everyone for your help.
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 

Author Comment

by:kearnguy
ID: 12219864
I thought I understood, but I can't get it to work.  There are obviously things I don't understand about div.  Could you please give me an example of the code.

I have a table with the main content that is set to automatically center.  Does this table need to be in the div?  So the css would be in the head tag and then my content in a table on a layer and it should all work right?

Thanks for being patient with a newbie CSS guy!
0
 

Author Comment

by:kearnguy
ID: 12221713
Nevermind...I figured out what I was doing wrong...

Everything worked wonderful!  I am raising the points to give 50 points to Roonaan for the great resource.  The original points go to OutsideTheBox for the great solution.

Thanks again!
0
 
LVL 3

Expert Comment

by:OutsideTheBox
ID: 12222685
Glad I could help, thanks for the points
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Deprecated and Headed for the Dustbin By now, you have probably heard that some PHP features, while convenient, can also cause PHP security problems.  This article discusses one of those, called register_globals.  It is a thing you do not want.  …
Any business that wants to seriously grow needs to keep the needs and desires of an international audience of their websites in mind. Making a website friendly to international users isn’t prohibitively expensive and can provide an incredible return…
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now