Stylesheet not recognised when .htaccess file added to root

New to mod_rewrite? This is a good place to start.

Stylesheet not recognised when .htaccess file added to root

Postby thevoid » Sat Oct 10, 2009 3:38 am

Hello,

I wanted to get rid of .php extensions, so used the .htacces code from the faq on this site. Here is the problem - my sites pages look something like this...

<?php include('header.html'); ?>

...some html...

<?php include('footer.html'); ?>

Obviously the link to the stylesheet is in the header.html file. When I request a page in my browser, it displays as if the stylesheet has been completely ignored, however when I "view source", the header has been included in the page's source code.

Cannot figure out what's going on here, very grateful for any pointers :)

Cheers.
thevoid
 
Posts: 3
Joined: Sat Oct 10, 2009 3:21 am

Postby DanielStutzbach » Sat Oct 10, 2009 7:46 am

What happens if you copy the style sheet's URL from "View Source" and paste it into your browser? Does it load that way?
DanielStutzbach
 
Posts: 6
Joined: Wed Aug 19, 2009 6:49 am

Postby thevoid » Sat Oct 10, 2009 8:49 am

DanielStutzbach wrote:What happens if you copy the style sheet's URL from "View Source" and paste it into your browser? Does it load that way?


Yes, if I click the link for the stylesheet in view source in Firefox, it shows the stylesheet - is that what you mean?
thevoid
 
Posts: 3
Joined: Sat Oct 10, 2009 3:21 am

Postby richardk » Sat Oct 10, 2009 9:53 am

What is your mod_rewrite?
Are you using relative paths? FAQ: Relative paths to images, JavaScript, CSS and other external/linked files are broken.
richardk
 
Posts: 8800
Joined: Wed Dec 21, 2005 7:50 am

Postby thevoid » Sat Oct 10, 2009 10:12 am

richardk wrote:What is your mod_rewrite?
Are you using relative paths? FAQ: Relative paths to images, JavaScript, CSS and other external/linked files are broken.


Thanks for the reply, that could be the problem. I can't try anything out right now, but will report back later if still having problems if that's ok...

cheers.
thevoid
 
Posts: 3
Joined: Sat Oct 10, 2009 3:21 am


Return to Beginner's Corner

Who is online

Users browsing this forum: No registered users and 6 guests

cron