CCS background.

O

Otuatail

I am still not able to set the bacground from a style sheet.

the code is simply

<style>
BODY {background-image: url("marble.gif") }
</style>

the code for the begining of the web page is

<html>

<head>
<meta http-equiv="Content-Language" content="en-gb">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>Recipe</title>
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta name="Microsoft Border" content="r, default">
<LINK REL=StyleSheet HREF="StyleSheet.css" TYPE="text/css" MEDIA=screen>
</head>
<body>

.........

The image is there and works when placed in the web page as

<body background="marble.gif">

any sugestions. I have put quotes around the file name. as well
 
E

Els

Otuatail said:
I am still not able to set the bacground from a style
sheet.

the code is simply

<style>
BODY {background-image: url("marble.gif") }
</style>

the code for the begining of the web page is

<html>

<head>
<meta http-equiv="Content-Language" content="en-gb">
<meta http-equiv="Content-Type" content="text/html;
charset=windows-1252"> <title>Recipe</title>
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<meta name="Microsoft Border" content="r, default">
<LINK REL=StyleSheet HREF="StyleSheet.css" TYPE="text/css"
MEDIA=screen> </head>
<body>

........

The image is there and works when placed in the web page as

<body background="marble.gif">

any sugestions. I have put quotes around the file name. as
well

I notice you left out the images/ part of the url. Where is
the gif? In the images folder?

What is the name of your stylesheet? StyleSheet.css or
stylesheet.css? It's better to not use uppercase letters in
filenames. And why are you placing <style> and </style> around
your code in the stylesheet? This might well be the problem.
Inside the stylesheet, there is no html. So you start from the
top, writing body {....} etc. The <style> tags are just
trouble when inside the stylesheet.
 
R

rf

Otuatail said:
I am still not able to set the bacground from a style sheet.

the code is simply

<LINK REL=StyleSheet HREF="StyleSheet.css" TYPE="text/css" MEDIA=screen>

Is your css file really called StyleSheet.css or is it stylesheet.css?

If it is then a URL is required.
 
R

rf

Els said:
Otuatail wrote:
The image is there and works when placed in the web page as

I notice you left out the images/ part of the url. Where is
the gif? In the images folder?

Er, why do gifs have to be in an "images" folder? A terrible lot of mine
aren't.
 
E

Els

rf said:
Er, why do gifs have to be in an "images" folder? A
terrible lot of mine aren't.

:-D
They don't have to be, but if they are, he'd better use
(images/marble.gif) instead of just (marble.gif).

It's from his previous post that I get the idea that the gif
is in the images folder :)
 
S

SpaceGirl

Els said:
I notice you left out the images/ part of the url. Where is
the gif? In the images folder?

What is the name of your stylesheet? StyleSheet.css or
stylesheet.css? It's better to not use uppercase letters in
filenames. And why are you placing <style> and </style> around
your code in the stylesheet? This might well be the problem.
Inside the stylesheet, there is no html. So you start from the
top, writing body {....} etc. The <style> tags are just
trouble when inside the stylesheet.

--
Els
http://locusmeus.com/
Sonhos vem. Sonhos vão. O resto é imperfeito.
- Renato Russo -

Are you allowed to quote urls? I thought it was supposed to be without
quotes.
 
E

Els

SpaceGirl said:
Are you allowed to quote urls? I thought it was supposed to
be without quotes.

I don't know, really...
I never use quotes on them though. I'll look it up later, you
got me curious now :)
 
O

Otuatail

I placed the image in both directories to try that out as well. The image and
it's path are ok.

In the web page I have

<LINK REL=StyleSheet HREF="StyleSheet.css" TYPE="text/css" MEDIA=screen>
<body>
Am I missing something here?
 
S

SpaceGirl

Otuatail said:
I placed the image in both directories to try that out as well. The image and
it's path are ok.

In the web page I have

<LINK REL=StyleSheet HREF="StyleSheet.css" TYPE="text/css" MEDIA=screen>
<body>
Am I missing something here?

Cut the confusion, change your filename to all lowercase, and do the same in
the markup. *never* use uppercase characters in your filenames when working
online - it just asks for problems like this. It's also a good idea to keep
your HTML in lowercase too - it'll make the migration to XHTML easier when
you are ready to move on from vanilla HTML.

miranda
 
O

Otuatail

Thanks to everyone who replied to this.
The answere was simply to remove
<style>
and
</strle>

from the strle shhet. Thanks again.

Desmond.
 
S

SpaceGirl

Otuatail said:
Thanks to everyone who replied to this.
The answere was simply to remove
<style>
and
</strle>

from the strle shhet. Thanks again.

Desmond.

This is why it's always best to post an url so people can look for you. Some
would have pointed that out in 3 seconds flat. ;)
 
R

rf

Els said:
:-D
They don't have to be, but if they are, he'd better use
(images/marble.gif) instead of just (marble.gif).

It's from his previous post that I get the idea that the gif
is in the images folder :)

It's from this OP right here that I determine that the image is in the same
folder as the html file. As in
 
R

rf

Otuatail said:
Thanks to everyone who replied to this.
The answere was simply to remove
<style>
and
</strle>

from the strle shhet. Thanks again.

So, you have wasted all of our time. Your thanks are refused.

Why did you not post a URL to the site right up front. Any one of us that
wasted our time replying to you and any one of the other probably hundreds
of people that did not reply but puzzled over your problem would have
spotted the problem IMMEDIATELY.

And if you really had </strle> in your style sheet you are doubly dammed!

Bah, Humbug. Sometimes I wonder why I donate my time to this newsgroup :-(
 
E

Els

rf said:
It's from this OP right here that I determine that the
image is in the same folder as the html file. As in

Got your point. But it seems to me the OP is not very precise in
his presentation of the problem. That's why I asked him where
the gif was.
 
E

Els

rf said:
And if you really had </strle> in your style sheet you are
doubly dammed!

That's what I meant with the OP not being very precise in his
presentation of the problem ;-)
Bah, Humbug. Sometimes I wonder why I donate my time to
this newsgroup :-(

For all the happy customers who pay you loads of money :)
 
D

Deryck

rf said:
Bah, Humbug. Sometimes I wonder why I donate my time to this newsgroup :-(
I can understand your frustration. However I am sure that I speak for others
when I say that I have found your posts useful, informative, and sometimes
entertaining.

I hope that you shall continue to post here.

Deryck
 
N

Neal

Er, why do gifs have to be in an "images" folder? A terrible lot of mine
aren't.

I do that so if I'm looking to update a specific file I don't have to wade
through all the image files, which I rarely have to update.
 
U

Uncle Pirate

rf said:
Bah, Humbug. Sometimes I wonder why I donate my time to this newsgroup :-(

Because you're just an all around nice guy? ;)

--
Stan McCann "Uncle Pirate"
Webmaster/Computer Center Manager, NMSU at Alamogordo
Cooordinator, Tularosa Basin Chapter, ABATE of NM AMA#758681
'94 1500 Vulcan (now wrecked) :( http://surecann.com/Dcp_2068c.jpg
A zest for living must include a willingness to die. - R.A. Heinlein
 
M

Mark Parnell

So, you have wasted all of our time. Your thanks are refused.

Well, admittedly Els did suggest that could be the problem. Of course I
totally agree on the posting a URL bit. :)
Bah, Humbug. Sometimes I wonder why I donate my time to this newsgroup :-(

Because you're addicted?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,055
Latest member
SlimSparkKetoACVReview

Latest Threads

Top