![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / |
#3
| |||
| |||
|
|
FF 2, IE 7 and NS 7 behave the same when I inline my styles as in this short example: head style body { font-family: Verdana, Arial, Helvetica, Tahoma, sans-serif; } p, h1, h2, h3, h4, h5, h6 { margin: 1em; } h4 { font-size: 100%; padding: 1px 0 1px 0; border-top: 1px solid red; background-color: #E4E4E4; } /style /head body <h4>Did Someone Say McDonald's?</h4 <p>Old McDonald has a farm ... </p /body But only IE7 renders the page correctly when I stuff everything between the style tags in an external stylesheet |
|
and link to it as in: head link rel="stylesheet" type="text/css" href="C:\Yada\css\default.css" / |
|
/head body <h4>Did Someone Say McDonald's?</h4 <p>Old McDonald has a farm ... </p /body I would be pleased to hear from anyone who can explain what causes the different behavior. |
#4
| |||
| |||
|
|
Hello to all, FF 2, IE 7 and NS 7 behave the same when I inline my styles as in this short example: head style body { .... |
|
But only IE7 renders the page correctly when I stuff everything between the style tags in an external stylesheet and link to it as in: head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / /head I would be pleased to hear from anyone who can explain what causes the different behavior. |
#5
| |||
| |||
|
|
whitesmith wrote: head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / What is a href to a local file? I'm rather surprised you got any styling on any of them! Regards Ian |
#6
| |||
| |||
|
|
In article 1193088721.513273.120... (AT) v23g2000prn (DOT) googlegroups.com>, whitesmith <apasse... (AT) hushmail (DOT) com> wrote: Hello to all, FF 2, IE 7 and NS 7 behave the same when I inline my styles as in this short example: head style body { ... But only IE7 renders the page correctly when I stuff everything between the style tags in an external stylesheet and link to it as in: head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / /head I would be pleased to hear from anyone who can explain what causes the different behavior. First look at where you have the html file. If the stylesheet is at the same level, change your link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / to link rel="stylesheet" type="text/css" href="default.css" / If it is in a folder underneath: link rel="stylesheet" type="text/css" href="folder/default.css" / If it is a folder above: link rel="stylesheet" type="text/css" href="../folder/default.css" / and like this... ("default" is probably not the best name, btw. The default style sheet is what the browser uses for all the styling not supplied by the author) -- dorayme |
#7
| |||
| |||
|
|
On Oct 22, 5:37 pm, dorayme <doraymeRidT... (AT) optusnet (DOT) com.au> wrote: First look at where you have the html file. If the stylesheet is at the same level, change your link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / to link rel="stylesheet" type="text/css" href="default.css" / If it is in a folder underneath: link rel="stylesheet" type="text/css" href="folder/default.css" / If it is a folder above: link rel="stylesheet" type="text/css" href="../folder/default.css" / and like this... |
|
I also put it in a folder below -- same result. The CSS validates, btw. Puzzling, is it not? |
#8
| |||
| |||
|
|
link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / to link rel="stylesheet" type="text/css" href="default.css" / I tried changing the name from default to custom -- same result. I also put it in a folder below -- same result. The CSS validates, btw. Puzzling, is it not? "\" is not valid syntax for an URL as a path delimiter. Although IE may |
#9
| |||
| |||
|
|
On Oct 22, 4:57 pm, Ian Hobson <ian.hob... (AT) ntlworld (DOT) com> wrote: whitesmith wrote: head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / What is a href to a local file? I'm rather surprised you got any styling on any of them! Regards Ian File location can't possibly make any difference. For example, Meyer ("Cascading Style Sheets: The Definitive Guide") references many instances of local sheets with hrefs looking exactly like mine. |
#10
| |||
| |||
|
|
whitesmith wrote: On Oct 22, 4:57 pm, Ian Hobson <ian.hob... (AT) ntlworld (DOT) com> wrote: whitesmith wrote: head link rel="stylesheet" type="text/css" href="C:\Yada\css \default.css" / What is a href to a local file? I'm rather surprised you got any styling on any of them! Regards Ian File location can't possibly make any difference. For example, Meyer ("Cascading Style Sheets: The Definitive Guide") references many instances of local sheets with hrefs looking exactly like mine. Except that "C:\Yada\css\default.css" is not a valid URL but a Windows filesystem path... URLs the slashes go the other way. My SeaMonkey would not load a stylesheet defined that way, it would have to be: "file:///C:/Yada/css/default.css" -- Take care, Jonathan ------------------- LITTLE WORKS STUDIOhttp://www.LittleWorksStudio.com |
![]() |
| Thread Tools | |
| Display Modes | |
| |