Trying a drop shadow design, IE won't let me.

This is a discussion on "Trying a drop shadow design, IE won't let me." within the Web Page Design section. This forum, and the thread "Trying a drop shadow design, IE won't let me. are both part of the Design Your Website category.



Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1 (permalink)  
Old Sep 21st, 2007, 20:23
New Member
Join Date: Sep 2007
Location: Sweden
Age: 27
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Trying a drop shadow design, IE won't let me.

Hi! I'm trying to develop a new design for a webpage of mine. I've come a bit on the way, but IE is giving me trouble. Maybe someone in here has an answer to my questions.

The main function of the site is to put a nice drop shadow around my photo. The site must be able to cope with different sized photos. My site will be written in php and the script can output the size of the photo if needed.

For my design, I have used some help from here: http://www.floatinginspace.za.org/cssshadow/

My developing site can be found here:
http://www.henrikhansen.se/csstest/


This is the HTML:
Code: Select all
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
 <head>
  <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
  <link rel="stylesheet" type="text/css" media="all" href="shadow.css" />
  <title>Dynamic css box with shadow</title>
  <style type="text/css">
   div.container {
    width: 900px;
   }
   div.containerw {
    height: 100%;
   }
   div.content {
    height: 100%;
   }
  </style>
 </head>
 <body>
  <div class="container">
   <div class="tlc"></div><div class="tll"></div><div class="tlt"></div>
   <div class="trc"></div><div class="trr"></div><div class="trt"></div>
   <div class="blc"></div><div class="bll"></div><div class="blb"></div>
   <div class="brc"></div><div class="brr"></div><div class="brb"></div>
   <div class="containerh">
    <div class="containerw">
     <div class="t"></div><div class="b"></div>
     <div class="l"></div><div class="r"></div>
     <div class="content">
      <img src="bild.jpg" alt="" width="900" height="603" />
      <p>I need room for a couple of lines of text here..</p>   
     </div>
    </div>
   </div>
  </div>
 </body>
</html>
This is the css:
Code: Select all
body {
 font-family: verdana,sans-serif;
 text-align: center;
 font-size: 13px;
 background-color:#66635d;
}
p {
 text-align: left;
 color: #000000;
}
div.container {
 background-color: transparent;
 margin: 20px auto;
 padding: 0 10px;
 position: relative;    
}
div.containerh {
 padding: 10px 0;
 background-color: transparent;
 margin: 0;
 position: relative;
}
div.containerw {
 background-color: transparent;
 padding: 1px 0;
 margin: 0 0;
 position: relative; 
}
div.content {
 background-color: #FFFFFF;
 padding: 10px 0 10px 0;       /*adjust padding if you set the height*/
 margin: -11px -10px -11px -10px;
}
div.l {
 width: 20px;
 height: 100%; 
 background-image: url(shadowlr.png);
 background-repeat: repeat-y;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 left: -30px; 
 top: 0;
}
div.r {
 width: 20px;
 height: 100%; 
 background-image: url(shadowlr.png);
 background-repeat: repeat-y;
 background-color: transparent;
 background-position: -20px 0;
 position: absolute; 
 right: -30px; 
 top: 0;
}
div.t {
 width: 100%;
 height: 20px; 
 background-image: url(shadowtb.png);
 background-repeat: repeat-x;
 background-color: transparent;
 background-position: 0 0;
 margin: 0 0;
 position: absolute; 
 left: 0; 
 top: -30px; 
}
div.b {
 width: 100%;
 height: 20px; 
 background-image: url(shadowtb.png);
 background-repeat: repeat-x;
 background-color: transparent;
 background-position: 0 -20px;
 margin: 0 0; 
 position: absolute; 
 left: 0; 
 bottom: -30px;  
}
div.tlt {
 width: 10px;
 height: 20px; 
 background-image: url(shadowlttbb.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 left: 0; 
 top: -20px;
}
div.trt {
 width: 10px;
 height: 20px; 
 background-image: url(shadowrttbb.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 right: 0; 
 top: -20px;
}
div.tlc {
 width: 20px;
 height: 20px; 
 background-image: url(shadowc.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 left: -20px; 
 top: -20px;
}
div.trc {
 width: 20px;
 height: 20px; 
 background-image: url(shadowc.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: -20px 0;
 position: absolute; 
 right: -20px; 
 top: -20px;
}
div.tll {
 width: 20px;
 height: 10px; 
 background-image: url(shadowtllrr.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 left: -20px; 
 top: 0;
}
div.trr {
 width: 20px;
 height: 10px; 
 background-image: url(shadowtllrr.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: -20px 0;
 position: absolute; 
 right: -20px; 
 top: 0;
}
 
div.bll {
 width: 20px;
 height: 10px; 
 background-image: url(shadowbllrr.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 0;
 position: absolute; 
 left: -20px; 
 bottom: 0;
}
div.brr {
 width: 20px;
 height: 10px; 
 background-image: url(shadowbllrr.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: -20px 0;
 position: absolute; 
 right: -20px; 
 bottom: 0; 
}
div.blc {
 width: 20px;
 height: 20px; 
 background-image: url(shadowc.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 -20px;
 position: absolute; 
 left: -20px; 
 bottom: -20px;  
}
div.brc {
 width: 20px;
 height: 20px; 
 background-image: url(shadowc.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: -20px -20px;
 position: absolute; 
 right: -20px;
 bottom: -20px; 
}
 
div.blb {
 width: 10px;
 height: 20px; 
 background-image: url(shadowlttbb.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 -20px;
 position: absolute; 
 left: 0; 
 bottom: -20px;  
}
div.brb {
 width: 10px;
 height: 20px; 
 background-image: url(shadowrttbb.png);
 background-repeat: no-repeat;
 background-color: transparent;
 background-position: 0 -20px;
 position: absolute; 
 right: 0;
 bottom: -20px; 
}
div.clear {
 clear: both;
}
table.counter{
    margin: 0 auto;
}
.center {
 text-align: center;
}
img {
 border: 0 none;
}
Does anyone have any ideas on how I can work my way around this problem?

EDIT: Should I mention that the site looks perfect in Opera and Firefox..?

Last edited by Henrik Hansen; Sep 21st, 2007 at 20:27.
Reply With Quote

  #2 (permalink)  
Old Sep 21st, 2007, 20:31
Marc's Avatar
Moderator

SuperMember
Join Date: Apr 2007
Location: Scotland, UK
Age: 15
Posts: 1,636
Thanks: 0
Thanked 6 Times in 6 Posts
Send a message via MSN to Marc Send a message via Skype™ to Marc
Re: Trying a drop shadow design, IE won't let me.

Let me give youa tip to start off... You know how you have "background-repeat: no-repeat;
background-color: transparent;" In nearly every class/id.... you could just do this:

Code: Select all
 * {
 background-repeat: no-repeat;
 background-color: transparent;
}
That means you dont need to put these two things anywhere else unless you wanted to change them and i would just do this as so:

Code: Select all
 container{
 background-repeat: repeat;
 background-color: #0000;
}
That would save alot of work (although it doesnt solve your problem... lemme see!)

EDIT: Is this not the same type of problem as this? http://www.webforumz.com/css-forum/6...-a-picture.htm

Last edited by Marc; Sep 21st, 2007 at 20:34. Reason: http://www.webforumz.com/css-forum/60003-add-shade-to-a-picture.htm
Reply With Quote
  #3 (permalink)  
Old Sep 21st, 2007, 20:44
New Member
Join Date: Sep 2007
Location: Sweden
Age: 27
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Trying a drop shadow design, IE won't let me.

Hi! Thanks for the quick reply and the point with transparency and no-repeat.

I checked the thread you suggested. I actually checked it before I posted the topic too, but it doesn't solve my problem. I can't do it in photoshop because I'm going to use php with my site and photos. Even more I will place text and buttons underneath the image, but inside the container. Kinda lika a polaroid photo with some things scrabbled under the photo.
Reply With Quote
  #4 (permalink)  
Old Sep 21st, 2007, 20:58
Marc's Avatar
Moderator

SuperMember
Join Date: Apr 2007
Location: Scotland, UK
Age: 15
Posts: 1,636
Thanks: 0
Thanked 6 Times in 6 Posts
Send a message via MSN to Marc Send a message via Skype™ to Marc
Re: Trying a drop shadow design, IE won't let me.

Mabey you should try the PHP forum?
Reply With Quote
  #5 (permalink)  
Old Sep 21st, 2007, 21:01
New Member
Join Date: Sep 2007
Location: Sweden
Age: 27
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Trying a drop shadow design, IE won't let me.

Quote:
Originally Posted by Marc View Post
Mabey you should try the PHP forum?

I have all the php I need. The problem is that I cant get the div:s to work properly in IE.
Reply With Quote
  #6 (permalink)  
Old Sep 22nd, 2007, 22:25
SuperMember

SuperMember
Join Date: May 2007
Location: UK
Age: 27
Posts: 1,111
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Trying a drop shadow design, IE won't let me.

Note that IE6 does not have native support for transparent PNGs.

Try my tutorial on this (coming in the October newsletter).
Reply With Quote
  #7 (permalink)  
Old Sep 23rd, 2007, 22:25
AdRock's Avatar
SuperMember

SuperMember
Join Date: Jul 2006
Location: Devon, England
Posts: 565
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to AdRock
Re: Trying a drop shadow design, IE won't let me.

I added a reply in the other topic as mentioned in a previous post here and that works perfectly for any size image...cehck it out...i included the neccessary images and CSS
Reply With Quote
  #8 (permalink)  
Old Sep 26th, 2007, 18:29
New Member
Join Date: Sep 2007
Location: Sweden
Age: 27
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Trying a drop shadow design, IE won't let me.

Interesting. I will try it when I get some time!
Reply With Quote
Reply

Thread Tools

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 On
Pingbacks are On
Refbacks are On

Similar Threads
Thread Thread Starter Forum Replies Last Post
CSS drop shadow effects with images wickedmoon Web Page Design 2 Aug 26th, 2007 22:01
Expanding background drop shadow konnor5092 Web Page Design 1 Feb 22nd, 2007 07:39
drop shadow?? karloff Graphics and 3D 7 Aug 4th, 2006 14:08
Need help Short Cut Keys on Drop Shadow in Fireworks csun Graphics and 3D 1 Jul 7th, 2006 13:23
Drop Shadow w/fireworks liquid Graphics and 3D 4 Dec 24th, 2003 09:15


All times are GMT. The time now is 03:18.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43