Webmaster Forum


Go Back   Webmaster Forum > Web Development > Web Design Lobby
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

Web Design Lobby Forum for general web design issues not specific to scripting or graphics.

   

Reply
 
LinkBack Thread Tools Display Modes
Old 09-05-2007, 04:06 AM   #1 (permalink)
v7n Mentor
 
Boogle's Avatar
 
Join Date: 09-03-07
Location: England
Posts: 645
iTrader: 0 / 0%
Latest Blog:
None

Boogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really nice
Talking CSS Background Image Problem

Hello peeps,

I am just getting into the whole fancy graphic designing thing but have come across one stupid problem that I can't seem to fix no matter how many blogs/forums i read so hopefully you guys will prove to be the most technically adept!

Basically i'm learning to create fancy menus, content holders etc so... cutting it short IE won't display background images if they're delcared within the stlye="" element of anything!, e.g.

<td background="http://www.v7n.com/forums/images/image123.gif"></td> works just fine BUT this is poor practise and I want to do it properly!

<td style="background: transparent url(images/image123.gif) no-repeat fixed center;"></td> DOES NOT WORK, for some reason IE won't render but you can drag your mouse over it and it's there!?

this is the design view, which works with CSS styles fine (ignore the site it's one i'm maintaining for someone and thus can use it to display my problems!)



This is the rendered view, in the development server mode; I have to drag the mouse over everything just to see that something is there!



Code:
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Demonstrator.aspx.cs" Inherits="Demonstrator" %> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head runat="server"> <title>Mobility Products UK</title> <style type="text/css"> .navmenuhome { width:160px; height:35px; background: transparent url(images/staticnavhome1.gif) no-repeat fixed center; font-family: "Trebuchet MS"; text-align:center; vertical-align:bottom; color:#ffffff; font-size:1.45em; } .navmenuwho { width:160px; height:35px; background: transparent url(images/staticnavwho.gif) no-repeat fixed center; font-family: "Trebuchet MS"; text-align:center; vertical-align:bottom; color:#ffffff; font-size:1.45em; } .navmenuwhat { width:160px; height:35px; background: transparent url(/images/staticnavwhat.gif) no-repeat fixed center; font-family: "Trebuchet MS"; text-align:center; vertical-align:bottom; color:#ffffff; font-size:1.45em; } .navmenucontactus { width:160px; height:35px; background: transparent url(/images/staticnavcontactus.gif) no-repeat fixed center; font-family: "Trebuchet MS"; text-align:center; vertical-align:bottom; color:#ffffff; font-size:1.45em; } .navmenucommunity { width:160px; height:35px; background:transparent url(/images/staticnavcommunity.gif) no-repeat fixed center; font-family: "Trebuchet MS"; text-align:center; vertical-align:bottom; color:#ffffff; font-size:1.45em; } </style> </head> <body> <form id="form1" runat="server"> <div></div> <div><img src="Images/Swift Logo 400 wide.jpg" alt="bannerPhoto" /></div><br /> <br /> <div style="width:800px;"> <table> <tr> <td class="navmenuhome">Home</td> <td class="navmenuwho">Who</td> <td class="navmenuwhat">What</td> <td class="navmenucontactus">Contact Us</td> <td class="navmenucommunity">Community</td> </tr> </table> </div> </form> </body> </html>
Basically, does anyone know why it won't render the backgrounds and text within <td>text</td> ?
If i havent submitted enouh info, guys please let me know,

Any help is much appreciated,
Thanks,

Boog's
__________________
Great new 'June' Javascript Framework
June Forums - Innovative JScripting

Price is what you pay... Value is what you get.

Last edited by Boogle : 09-05-2007 at 04:35 AM. Reason: I am a rusher and didn't get it right first time!
Boogle is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:21 AM   #2 (permalink)
v7n Mentor
 
Costin Trifan's Avatar
 
Join Date: 04-13-07
Location: Romania
Posts: 3,009
iTrader: 0 / 0%
Costin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web pro
You have this:
<td style="transparent url(images/image123.gif) no-repeat fixed center;"></td>

Try this:
<td style="background:transparent url(images/image123.gif) no-repeat fixed center;"></td>

____
Edit:
If you can edit your post, edit it and wrap the styles in [ code ]...[/ code ]. This way you'll make chicgeek happy
Costin Trifan is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:23 AM   #3 (permalink)
v7n Mentor
 
Boogle's Avatar
 
Join Date: 09-03-07
Location: England
Posts: 645
iTrader: 0 / 0%
Latest Blog:
None

Boogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really nice
Sorry, Costin, i wrote that out a bit fast, if you check the code i have already done it correctly in there!

i will edit that post, apologies for the confusion,

Boog's
__________________
Great new 'June' Javascript Framework
June Forums - Innovative JScripting

Price is what you pay... Value is what you get.
Boogle is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:26 AM   #4 (permalink)
v7n Mentor
 
Costin Trifan's Avatar
 
Join Date: 04-13-07
Location: Romania
Posts: 3,009
iTrader: 0 / 0%
Costin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web pro
ahh..sorry, didn't see it...

anyway, still not showing? try this:

<td style="background-color: Transparent; background-image: url('images/image123.gif') no-repeat fixed center;"></td>

see if this works.
Costin Trifan is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:34 AM   #5 (permalink)
v7n Mentor
 
Boogle's Avatar
 
Join Date: 09-03-07
Location: England
Posts: 645
iTrader: 0 / 0%
Latest Blog:
None

Boogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really nice
No, Costin,that doesn't work either, it's strange because i read that you must emit the code in the following order:

color
url
repeat
attachment
position

and this accomodates, IE's requirements, yet it does nothing! why can't their be just one nice browser that makes life easY!?
__________________
Great new 'June' Javascript Framework
June Forums - Innovative JScripting

Price is what you pay... Value is what you get.
Boogle is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:44 AM   #6 (permalink)
v7n Mentor
 
Costin Trifan's Avatar
 
Join Date: 04-13-07
Location: Romania
Posts: 3,009
iTrader: 0 / 0%
Costin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web pro
Quote:
why can't their be just one nice browser that makes life easY!?
yeah, right!!
It's every web designer dream, but unfortunately, a dream that will never come true

As for practice I always use the long part:
Quote:
background-color: #ffffff;
background-image: url('');
background-position: top left;
background-repeat: repeat;
and not the short one as you did.

And I do have one question though:
Where in your page you want to display that cell with that background image?
I couldn't find it.

Can you be a little more specific about that and if you can attach that image you need I can have a look on my computer and see if I can do something about it.
Costin Trifan is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 04:54 AM   #7 (permalink)
Contributing Member
 
bratwebdesign's Avatar
 
Join Date: 04-05-06
Location: Nebraska
Posts: 560
iTrader: 0 / 0%
Latest Blog:
None

bratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to beholdbratwebdesign is a splendid one to behold
Send a message via MSN to bratwebdesign
Does the background render on the text Home and Who? The reason why I ask is because in the style part of the page, Home and Who show the images located in images. While Contact, Community and What show the images located in /images. This could make the background image not show and being that the text is white, it would not show up on a white background.
__________________
Omaha Web Design | Cube Directory
bratwebdesign is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 05:17 AM   #8 (permalink)
v7n Mentor
 
Boogle's Avatar
 
Join Date: 09-03-07
Location: England
Posts: 645
iTrader: 0 / 0%
Latest Blog:
None

Boogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really niceBoogle is just really nice
Guys, thanks for the super fast replies, but i've solved the problem now,

the code in error, which is fully my own fault, was
Quote:
background:transparent url(images/staticnavcommunity.gif) no-repeat fixed center;
it should have been
Quote:
background:transparent url(images/staticnavcommunity.gif) no-repeat scroll center;
Can someone explain that to me please!?

Thanks again, this forum is a dedicated one, i will be showing the same attitude whenever i can help people!

Boog's
__________________
Great new 'June' Javascript Framework
June Forums - Innovative JScripting

Price is what you pay... Value is what you get.
Boogle is offline  
Add Post to del.icio.us
Reply With Quote
Old 09-05-2007, 05:44 AM   #9 (permalink)
v7n Mentor
 
Costin Trifan's Avatar
 
Join Date: 04-13-07
Location: Romania
Posts: 3,009
iTrader: 0 / 0%
Costin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web proCostin Trifan is a highly respected web pro
Quote:
background-attachment
Sets whether a background image is fixed or scrolls with the rest of the page
http://www.w3schools.com/css/css_background.asp

Costin Trifan is offline  
Add Post to del.icio.us
Reply With Quote
Go Back   Webmaster Forum > Web Development > Web Design Lobby

Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

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

vB 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
quick question css FF background image funguru Coding Forum 12 03-27-2007 08:50 PM
CSS background image IE paranoidandroid Coding Forum 3 06-04-2006 01:28 PM
Still Background Image TheGunslinger Web Design Lobby 3 08-09-2005 08:00 PM
Making the background image NOT repeat. wbstein Web Design Lobby 4 05-30-2004 11:45 AM
Table Background Image Jazzee Coding Forum 5 11-16-2003 09:05 PM


Sponsor Links
Get exposure! Get exposure! Find Scripts Web Hosting Directory Get exposure! SEO Blog


All times are GMT -7. The time now is 07:31 AM.
© Copyright 2008 V7 Inc