Title: Permalinks and CSS
Last modified: August 19, 2016

---

# Permalinks and CSS

 *  Resolved [mtibbits](https://wordpress.org/support/users/mtibbits/)
 * (@mtibbits)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/)
 * I am having an issue where my CSS file for my theme is not loaded when using 
   Permalinks.
 * When I change back to the default Permalink structure all pages work fine.
 * This IS when I’m working with Pages and NOT posts.
 * I created a custom Permalink and used /%pagename%. This works for first level
   pages. Ex. website.com/about-us.
 * However, if I have a 2nd level page that is a child of the first, it again shows
   the page, without any CSS formatting. Ex. website.com/about-us/annual-report.
 * Can anybody help with this at all? I have a bit of a complicated navigation system
   for this site, and this will be much easier with Permalinks instead of using 
   the page IDs.
 * Thanks,
 * Matt

Viewing 5 replies - 1 through 5 (of 5 total)

 *  [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * (@doodlebee)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971784)
 * sounds like you’re using relative paths to call in your CSS files. That won’t
   work. Of course, guessing what the issue is doesn’t help much either. it would
   help a lot more if you’d provide a link to the site in question.
 *  Thread Starter [mtibbits](https://wordpress.org/support/users/mtibbits/)
 * (@mtibbits)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971799)
 * I am using relative paths…can I not do this?
 * I have everything on a local testing server for now so I don’t have a link to
   the site. If need be I will upload later this evening.
 *  [Doodlebee](https://wordpress.org/support/users/doodlebee/)
 * (@doodlebee)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971804)
 * >>I am using relative paths…can I not do this? <<
 * if you do, this is what will happen.
 * You forget that WordPress is a system that uses includes to call things in from
   different areas. If you have it working with a relative path on one page, then
   when you go another level down, it won’t work anymore – because the relative 
   path you’re using doesn’t change. I.e. “../images” won’t change to “../../images”
   just because you go in a level deeper. Your header in an included file – it’s
   the same across ALL pages.
 * So no, don’t do that. Use the full path:
 * `<?php bloginfo('template_directory'); ?>`/rest of the path here
 * If it’s just to your stylesheet, you should have the stylesheet path in there:
 * `<?php bloginfo('stylesheet_url'); ?>`
 *  Thread Starter [mtibbits](https://wordpress.org/support/users/mtibbits/)
 * (@mtibbits)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971808)
 * Ok, I used:
 * `<?php bloginfo('stylesheet_url'); ?>`
 * for my default stylesheet and it is working. One last question is: how do I then
   link to my print and my IE only stylesheets? They are in the same location, but
   have a different name than the default style sheet.
 *  Thread Starter [mtibbits](https://wordpress.org/support/users/mtibbits/)
 * (@mtibbits)
 * [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971812)
 * Sorry, I guess you already answered that with:
 * `<?php bloginfo('template_directory'); ?>/rest of the path here`
 * Thank you very much for your help!
 * Matt

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Permalinks and CSS’ is closed to new replies.

## Tags

 * [css](https://wordpress.org/support/topic-tag/css/)
 * [permalinks](https://wordpress.org/support/topic-tag/permalinks/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 5 replies
 * 2 participants
 * Last reply from: [mtibbits](https://wordpress.org/support/users/mtibbits/)
 * Last activity: [17 years, 4 months ago](https://wordpress.org/support/topic/permalinks-and-css/#post-971812)
 * Status: resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
