Forum Moderators: not2easy
I have looked around on the net for a solution but I honesty think its not my fault, I think its something to do with something my ISP is blocking.
My HTML header:
<!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>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Main Page</title>
<link href="Style.css" rel="stylesheet" type="text/css" />
</head>
body {
background-image: url(background.jpg);
background-repeat: repeat;
}.title {
font-family: Georgia, "Times New Roman", Times, serif;
font-size: 72px;
color: #FFFFFF;
}
.subtitle{
font-family: Georgia, "Times New Roman", Times, serif;
font-size: 48px;
color: #FFFFFF;
}
Ive got my index.html, Style.css, and background.jpg file all on the root of my server, but the only thing that shows is my index.html file with no formatting, and the background image does not show up. Any ideas?
[edited by: Tumdace at 7:41 pm (utc) on June 30, 2009]
In thoose cases, I usually test my page in a specific css editor. In there the document work well, it is surely a server problem. You can use this tool: <>
[edited by: SuzyUK at 12:25 pm (utc) on July 2, 2009]
[edit reason] no URIs per Charter [WebmasterWorld.com] [/edit]
http://example.com/background.jpg
If you can't see the image, it may mean it's been uploaded in ASCII mode. Images, Flash, and other non-text data needs to be uploaded in binary mode.
If you can see the image in that case, go back to the page and hold down the CTRL key (Apple key for Mac) and press F5 (or hit reload/refresh button.) This forces a full refresh of the page, rather than using cached copies. You may have cached a previous broken version of your page. Browsers are selfish when it comes to included CSS and JS files and sometimes keep previous cached files.
If it still doesn't work, this is probably not going to be any different, but you could try
body { background: url(background.jpg) repeat; }
You could try adding a leading slash,
body { background: url(/background.jpg) repeat; }
Shouldn't make any difference though.
Or did you mean putting in MY ip adress and then /background.jpg?
Right, we can't post specific site URL's here so you will see "example.com" a lot. Take it one step further, if you request the URL/URI to your CSS, it should do the same - display your CSS (In FireFox only, it may try to open a "helper" program in IE.)
Cause if I do that, it just shows me the url on the page again.
Say what? You put "yoursite.com/background.jpg" in the address bar and it displays a page that is all white with only the text of the URL on it?
I have seen this in some PHP applications that weren't functioning correctly, I have no other explanation for it. If the above accurately describes the problem, there is something else at play, possible something in an .htaccess directive or server configuration redirecting requests.