• Hi All!
    I have a custom theme whose style has disappeared, although style.css is in the theme folder and I can edit it using the theme editor from the WP Dashboard.

    Earlier today I made up some templates for pages that use a different database than what is used for WP. These password-protected pages use their own stylesheet, which is working just fine and located in the public_html folder.

    Since I can see the blog stylesheet in the theme editor and make changes (which I’ve verified via FTP), I’m really confused. So far, I’ve tried these things to get back the formatting:

    • uploaded stylesheets that I prepared locally to replace the missing one, but that did not bring back the formatting/style
    • modified the theme header.php from
      <link rel="stylesheet" href="<?php bloginfo('stylesheet_url'); ?>" type="text/css" media="screen" />
      to have an absolute path for the css like so,
      http://piedmontsar.org/wp-content/themes/search-n-rescue_copy/style.css, and even a relative one like so,
      wp-content/themes/search-n-rescue_copy/style.css
    • viewed to be the same in IE7 and FF before and after deleting browsing history/cache and closing browsers

    All I see is plain text but the content is correct so the blog appears to be functioning ok other than the missing formatting. It should be a greenish design with a header of barren trees. Here’s the link: http://piedmontsar.org/

    Total Validator complains about a missing file:

    E404 Problem with link:
    <link rel=”stylesheet” href=”http://piedmontsar.org/wp-content/themes/search-n-rescue_copy/style.css&#8221;
    type=”text/css” media=”screen” />

    where E404 = “Not Found: The remote server could not find a document at the URL provided. The link may refer to a document that no longer exists, or is pointing to the wrong place.”

    BTW I am getting the same error for favicon.ico, which I have not messed with lately – it’s also located inside the search-n-rescue_copy theme folder.

    What am I missing here?? ANY help is truly appreciated!

Viewing 12 replies - 1 through 12 (of 12 total)
  • Lizzy,

    I tried to view your CSS file using the Web Developer Toolbar and only see xhtml. Are you sure your style.css file is only CSS? It looks to me like it’s actually been overwritten with xhtml.

    Certainly could be and something else is blocking me from seeing it.

    How ’bout permissions on the file? 644?

    An unrelated side note: you’ve some validation errors because you’re using id=”post” for each post instead of a class=”post” – just so you know.

    Thread Starter LizzyFin

    (@lizzyfin)

    I’m afraid I don’t know what you mean that you ‘only see xhtml’ when viewing the style.css file. What would tell you that it’s been overwritten with xhtml?

    I took a prior version of the stylesheet and uploaded it and refreshed my browsers. I did this a number of times with different versions of the style.css and have the same results each time.

    I don’t understand how the W3C validator can’t find the file because I can see that it is there and have tried various permissions, 666, 644 to no avail. I can ftp a copy of a working stylesheet with a different name and then change the name to style.css check permissions and still have the unformatted output. Why can I then download said file and read it, alter and re-upload it?

    Beyond that I think the file is actually css. I opened the latest copy on the server (666) into html-kit, copy-n-pasted into the direct input of W3C Validator and the css validates.

    Thank you for the note on class=”post”, sewmyheadon!
    Still lost!

    Thread Starter LizzyFin

    (@lizzyfin)

    To check my file even further as to its css-ness…I double checked that style.css was working properly on my local server (also using WP v2.5.1) and used the file upload feature of the W3C Validator to make absolutely certain I was using the same file and, yet, the css validates.

    When I upload the same stylesheet to my online server, the pages of the web site that call it can not find it, nor can the W3C Validator when checking the xhtml of files that are supposed include the style.css file.

    Style.css has permissions of 666.

    Thread Starter LizzyFin

    (@lizzyfin)

    Besides, if the stylesheet was actually missing from the theme folder, then the theme would be reported as broken, right?

    So, WP is really finding style.css??

    When I use Firebug to inspect the head of <http://piedmontsar.org/&gt; there is a plus sign next to the link for the css file:

    <link media=”screen” type=”text/css” href=”http://piedmontsar.org/wp-content/themes/search-n-rescue_copy/style.css&#8221; rel=”stylesheet”>

    In Firebug, clicking the plus sign to see the contents of the css file gives 186 lines of what would be a ‘not found’ generic 404 and not the css file as it should be.

    How is this happening? I have another blog that I have been checking everything against (it is also v2.5.1 and its working fine) to troubleshoot this problem and can’t understand what is going on here.

    Lizzy,

    I’m afraid I don’t know what you mean that you ‘only see xhtml’ when viewing the style.css file. What would tell you that it’s been overwritten with xhtml?

    That’s just what I saw using the Web Dev Toolbar in FF, but if there’s another issue, it’s probably wrong.

    I’m a bit at a loss here. Seems you’ve tried a bunch of things to no avail. I’d hope it was just something simple, but, well, hmm . . .

    Do you happen to have any plugins installed and activated on the server that you don’t have on your local dev machine? Have you tried disabling all plugins?

    How’s your .htaccess file on the server?

    I’d be happy to help troubleshoot further if you’d like to contact me directly.

    eric

    check and see if your server has a forward taking place.. it may be that you are pointing to the css file but the server is redirecting (301 redirect) to your home page…

    when I try to load your css I get your home page- without style.

    Thread Starter LizzyFin

    (@lizzyfin)

    Eric, thank you so much for helping me troubleshoot this “missing” css file. To update, the problem is resolved now. I’m not sure what had happened to the style.css file, but the fix turned out to be as simple as downloading the entire theme folder, then re-naming the stylesheet with a new theme name and uploading the “new” theme.

    Switching themes did not bring back the formatting of the css until I deleted the ‘old bad’ theme. That didn’t make sense to me, but anyway the new theme is working as intended!

    I think I’m having a version of your issue LF, but I’m not nearly as competent as you in trying to troubleshoot. I’ve uploaded the Freedom – Green & Widgetized theme from the theme directory. The “about” box is managed from the sidebar.php file, but when I try to make changes to this file in the WP theme editor I get “The requested theme does not exist.” error message. The theme is in place on my (empty) blog, so I’m not sure what doesn’t exist. (blog.irishviolet.com)

    If I understand what you did, do I need to download the theme folder, make the changes on my desktop, rename the file and re-upload?

    thanks,
    Tim F.

    Thread Starter LizzyFin

    (@lizzyfin)

    TimF, I saw that exact error (“The requested theme does not exist.” ) a couple times when I was trying to figure out what happened to my theme. If you change the name of the theme in the style.css while that theme is active, that is one way to produce that error.

    I would try to do just that…download the theme, give it a new name, upload it, switch themes and delete the old one.

    Cross your fingers, too, and let us know if it worked!
    Good luck!

    Congrats on solving it, Lizzy. Wish I’d been able to tell you exactly what happened, but . . .

    Well, backup, backup, backup, eh? πŸ™‚

    Nope didn’t work, but other themes I added the same way are editable, so now I think it must be something in the css or other file of the original template I wanted to use. Pity.

    thanks,
    Tim F.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Stylesheet/css present but not formatting’ is closed to new replies.