![]() |
| |||||||
| HTML Forum HTML Forum. HTML Programming questions and answers here. |
![]() |
| | LinkBack | Thread Tools | Search this Thread | Display Modes |
| |||
| Style sheets & Mozilla
Hi All, I'm having a bit of a problem with a style sheet. I thought it could perhaps be a path problem, but I've eliminated that one by dropping it into the document root and the behaviour remained the same. The link is between the '<head></head>' tags and works in IE, but not Mozilla. So I tried '<style>@import url(..Styles/sheet.css); </style>' wich also works fine in IE, but didn't in Mozilla. As the page is generated via php I eventualy loaded the sheet into a var and embedded it, which works fine in either browser. Although I've found a workable solution I'm still very curious and would like very much to know why the standard methods are not working for me in Moz. Any info or help with this is more than welcome, TIA Vince Morgan |
| |||
| Style sheets & Mozilla "dorayme" <doraymeRidThis@optusnet.com.au> wrote in message news:doraymeRidThis-ADDA69.13022904112006@news-vip.optusnet.com.au... Hi Dorayme, The IE vers is 6.0.2800.1106; Mozilla ActiveX Control v1.7.12; OS win2000. The IDE is Dev-PHP 2.0.12. I'm working in an IDE (local server) as I don't have a server on this (win2000) machine. However, below I have included code that replicates the problem when using <link>. The directory struct is, Root |-\Styles |-\HTML In the 'HTML' dir; <snip> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <meta http-equiv="Page-Enter" content="blendTrans(Duration=0.2)"> <meta http-equiv="Page-Exit" content="blendTrans(Duration=0.2)"> <link rel=StyleSheet href="../Styles/reqHeader.css" type="text/css"> <script type="text/javascript"> var theForm = null; </script> </head> <body> <div class="Head">This is a test.<div> </body> </html> </snip> In the 'Styles' dir; <snip> ..Head { color:#306090; font-family:Helvitica, Arial; font-weight:Bold; font-size:16px; } </snip> Perhaps the Mozilla control doesn't work exactly the same as the stand-alone browser? Thinking aloud textualy ![]() Vince |
| |||
| Style sheets & Mozilla
In article <454c11ca$0$22937$afc38c87@news.optusnet.com.au> , "Vince Morgan" <vinhar@UNSPAMoptusnet.com.au> wrote: First thing I notice is no "" around the word Stylesheet in the link to the sheet. But this is perhaps no problem. Next I notice a failure to close the div after the test sentence. I reckon this is a bit more important. Anyway, on the Mac version of Mozilla (1.7.12) it does not stop it from appearing ok and being controlled by the css when the file directory is as follows: the css is in a folder (called Styles) within another folder. In this last folder is another folder which contains the html file. OK, lets take this again. I made a folder called "top", inside I had 2 folders, one called "Styles" and one called "html". Inside Stles was reqHeader.css while inside html was test666.html. This had to be like this otherwise, no go. So are you getting your paths right? -- dorayme |
| |||
| Style sheets & Mozilla
"dorayme" <doraymeRidThis@optusnet.com.au> wrote in message news:doraymeRidThis-A63E87.18392504112006@news-vip.optusnet.com.au... Yes, sorry, my bad Dorayme. Such a small piece of code too. Neither of those errors actualy made any difference to the problem though. It seems from the above that your directory structure, the one that works, is exactly as mine is here. It still won't work within the IDE I'm using, but it's quite possible that it will on my employers server. I guess I'll find out tomorrow, all going well. The workaround is suitable so I won't frett too much about it. Thank you very much for taking the time to check it for me Dorayme. Regards, Vince |
| |||
| Style sheets & Mozilla
In article <454d7a3e$0$11968$afc38c87@news.optusnet.com.au> , "Vince Morgan" <vinhar@UNSPAMoptusnet.com.au> wrote: The only other thing is ... perhaps it has been mentioned... some servers are case sensitive, some not. Check carefully to have the exact names re case in the links... -- dorayme |
| |||
| Style sheets & Mozilla
Vince Morgan wrote: [snip] When PHP was generating the style sheet, did you set the Content-Type header appropriately? Mozilla will, quite reasonably, refuse to use a style sheet that isn't labelled with the text/css MIME type. This would have been reported in the error console. [snip] If you still have problems, post a /link/ to a simple demonstration. Mike |
| |||
| Style sheets & Mozilla
Vince Morgan wrote: I suppose you meant "../Styles/sheet.css". Mozilla respects the concept of DocumentRoot. If <Styles> is located above the DocumentRoot, Mozilla cannot get to it. IE ignores such pesky standards limitations. -- jmm (hyphen) list (at) sohnen-moe (dot) com (Remove .AXSPAMGN for email) |
| |||
| Style sheets & Mozilla
Michael Winter wrote: Yeah, good point. There server should prevent any such inappropriate behavior. I am not sure what issue I was thinking about when I wrote that, but the above is drivel. -- jmm (hyphen) list (at) sohnen-moe (dot) com (Remove .AXSPAMGN for email) |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Css Style sheets help? | titchyc | CSS Forum | 1 | 06-17-2008 10:21 PM |
| Having trouble with CSS Style Sheets? | olddrugdealer | CSS Forum | 0 | 02-19-2008 11:19 AM |
| CSS Mozilla: Make Mozilla not ignore height style of an inline element | Henri | HTML Forum | 9 | 02-22-2005 05:08 PM |
| Style sheets, include one style within another (not inheritance) | foldface@yahoo.co.uk | HTML Forum | 1 | 11-24-2003 12:37 PM |
| IE & Mozilla style sheets | Robert Secon | HTML Forum | 3 | 11-11-2003 08:37 AM |