WordPress.org

Forums

[resolved] Stylesheet not applying; custom theme. (9 posts)

  1. ryansigg
    Member
    Posted 7 years ago #

    Hi.
    I'm am creating my first WP theme. It is a
    design from another site that I'm trying to
    turn into its own theme.

    The problem is that the stylesheet
    seems to either be linking incorrectly or simply
    not applying for some reason; I would suspect the
    latter because under "Presentation" in the "Theme
    Editor" the correct stylesheet appears, so it seems
    to be finding the correct file.
    None of the instructions in the stylesheet are
    displaying: layout, images, formatting...

    {i took it to the W3C validator just for kicks and
    it said i got a 404 error (?)}

    Also this stylesheet presents no problems when
    it's applied in the non-WP version of the site,
    but here is how I am linking it:
    <link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" />

    this is the site:

    http://www.mamascience.net/flog/

    and here is a link to the stylesheet
    (note: though the file is the same, this is
    a different location since I can't call the
    stylesheet from it's direct URL in the Wp diretory):

    http://www.mamascience.net/test/style.css

    This seems(?) to be a simple problem that I
    am just too much of a novice to see...
    Please let me know if you need to see anything
    else to illustrate the problem.

    Any help?
    thanks mucho in advance...

  2. Cathy Tibbles
    Member
    Posted 7 years ago #

    Hi there, I don't have an answer for you - but which css sheet are you using to build your own wp theme? and is there a tutorial that you are following? (i also am attempting to adapt a theme, and completely overhaul the css)

    thanks!
    Cathy

  3. Jeremy Clark
    Moderator
    Posted 7 years ago #

  4. Cathy Tibbles
    Member
    Posted 7 years ago #

    <link rel="stylesheet" type="text/css" href="mystyles.css"> is the linking relationship that I studied at yourhtmlsource dot com.

  5. ryansigg
    Member
    Posted 7 years ago #

    um. thanks jeremyclark, but that is where I started. I am stuck with a specific problem (I believe) and I need a specific (as there can be offered) answer.
    The theme is not providing any problems in the admin panel, ie. it seems to recognized by WP as a theme.

    I have linked to the stylesheet in a few different ways,
    by calling it directly and thru WP's tag...
    Anyone else, maybe take a peek?
    thanks...

    BTW, Cathy, the tutorial that i initially followed is here.

  6. moshu
    Member
    Posted 7 years ago #

    Since everything is missing from the top of that stylesheet you linked to... it can NOT be OK, even in your presentation subpanel.

    Next, that tutorial is not telling you anything that you couldn't find in any average theme.
    Plus it is missing ALL the information you need to put in the stylesheet.

    Follow Jeremy's link and read everything in the Codex.

  7. ryansigg
    Member
    Posted 7 years ago #

    Moshu,
    Pardon me, I'm not trying to be stubborn (then again, no-one really tries to be...):

    1st: I have changed a couple things in my stylesheet, and it validates as CSS... but there is nothing missing (that I can see) from the top that a stylesheet usually requires (?).
    Maybe I wasn't clear about the Presention subpanel; the correct stylesheet IS appearing in the "theme editor". All I meant by that is that is seems to be linking to the correct stylesheet.

    2nd: I don't think that anyone should come to the forums without looking in the Codex first, and I haven't done any differently. I've read much of the theme creation sections in the codex, and am still doing so... Merely pointing me to an entire category in unhelpful and kind of rude, since we all start there.
    Therefore, if you think there is a section that would help me (barring the entire Blog_Design_and_Layout category) it would be helpful to point me there.
    Or, if you think that the entire thing is so messy that you can't look at for fear of searing your eyeballs, just please say that. Please say "this is the work of an imbecile. learn something," and even though I've already admitted to being one, I will do so. I'll "follow Jeremy's link and read everything in the Codex" and then you'll probably still see me back here.

    3rd: that tutorial (i think) merely provides an intro to the partitioning of a "normal" website into different WP theme sections, which i think is helpful for those of us who design "static" webpages but are not used to dealing with dynamic data-base driven sites, something which is not often enough addressed accessibly in the codex (BTW, you should add a chapter in your book about that. I'd buy it.)

  8. moshu
    Member
    Posted 7 years ago #

    That's too long to answer it in details... sorry.
    Then you gave some totally irrelevant links in your previous posts.

    The stylesheet you were trying to show at this link:
    http://www.mamascience.net/test/style.css
    IS NOT A WP THEME STYLESHEET. That's why I sent you back to the Codex.
    A theme's stylesheet MUST have this at the top:

    /*
    Theme Name: Whatever
    Description: 3 column fluid
    Author: Moshu
    Author URI: etc.
    */

    What you linked above does not have it. That's the reason I said: it cannot show up correctly in your Presentation subpanel.

    Also, look at the default or classic how the stylesheet is called in the header.php - and you should be good to go.

    [No, there will be no "making a theme" chapter. The book is for thsoe that cannot tell ftp from pdf :) ]

  9. ryansigg
    Member
    Posted 7 years ago #

    thanks for the help... that's exactly what i needed to hear...
    now i just need to work out the CSS errors ;)

Topic Closed

This topic has been closed to new replies.

About this Topic