CSS Background


#1

Hi guys, I don’t know if anyone who posts here has any experience with CSS, but I gots a question.

I’m trying to have CSS display a background that is repeated in the x-direction. Here’s the code I’m using:

<style type="text/css">
body
{ 
background-image: 
url("images/background.jpg");
background-repeat: repeat-x
}
</style>

It has to display in Safari, by the way. I’ve seen the same sort of script work on Safari browsers, though.


#2

That seems to work for me. Are you having a problem with it?

I think you need to put in some actual content before it will render.

menino.com/temp is an example of your code. Works fine on Safari and Firefox.


#3

can you test this for me?

207.194.110.53/test/

I don’t know any Mac people at home today. There’s a green java menu on the left that will not show with Konqueror, but it’s ok with anything else I tried.
It behooves as to why but who uses Konqueror anyway?
thx.

(it’s also a compressed page)


#4

Works with Safari.


#5

thx. I guess I need another reason to talk my partners into a G5, huh?
The print shop, we ‘need’ it for the print shop, heh heh…


#6

Yeah, no background is even showing for me, which is a pain. I’m using it in a JSP though, and I’m using an external .css file so that may be the problem. The weird thing is, the other attributes from the CSS are being used properly.


#7

And if you go to menino.com/temp you don’t see the background?


#8

I see your background…

I have my code in an external .css file and that seems to be the problem.


#9

And how are you calling it? Can you give us a URL to look at?

I’ve just moved the CSS to an external file, and it still seems to be working fine in safari. menino.com/temp

Perhaps it’s just a path thing? Is the background really in a directory called images?


#10

what’s your index page header code? or try copy & paste the css code section to another spot on your style sheet.


#11