|
Mailing Lists
|
Home /
Groups /
Cascading Style Sheets (CSS)
style sheets not being applied in firefox
Cool. Does cf actually parse the file? My understanding is that because itDouglas Hyde 02/20/09 09:40 A Use cfcontent to set the correct mime type.Peter Boughton 02/20/09 11:30 A Slightly more helpfully, here's what you need...Peter Boughton 02/20/09 11:35 A I have just developed a site from a template that uses a couple of style sheets. The site renders fine in chrome and ie, but not firefox. I am using stylesheets with a .cfm extension, something I am trying the first time, because they use image references and I wanted to make them dynamic. Could that be causing the issue or is it something else? Here are the tags referencing the style sheets. Hopefully you guys can spot what I am doing wrong. <link href="/version0dot2/includes/www_mysite_com/layoutfiles/style.cfm" rel="stylesheet" type="text/css" /> <link href="/version0dot2/includes/www_mysite_com/layoutfiles/layout.cfm" rel="stylesheet" type="text/css" /> <base href="http://mysite.com/version0dot2/"> Cool. Does cf actually parse the file? My understanding is that because it is a link, the web server doesn't actually parse the file, the browser does? So, the hook to coldfusion isn't there, and it doesn't parse any cfoutput within the file? Maybe I am wrong? I tried this myself, and ended up going to cfinclude because I couldn't get it working. ----- Excess quoted text cut - see Original Post for more ----- Use cfcontent to set the correct mime type. This applies to both css and javascript. Slightly more helpfully, here's what you need... <cfheader name="Content-Type" value="text/css"/> That one is copied from a file in use, but I'm fairly sure cfcontent works and is probably more readable: <cfcontent type="text/css" /> Also useful to ensure showdebugoutput is turned off to prevent the debug info causing errors in the file.
|
May 25, 2013
|
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||