WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] Child Theme not working (21 posts)

  1. mrmccarrin
    Member
    Posted 1 year ago #

    Hi - My child theme is not working and I do not understand why? All the code will work when i use CSS Manager, but i wanted to know what was wrong with my child theme for my own future reference.

    Here is what I did:

    I created a file name style.css and put this content in:

    [ Moderator Note: Please post code or markup snippets between backticks or use the code button. ]

    /*
    Theme Name: Twentytwelve Child
    Description: Child theme for the twentytwelve theme
    Author: Your name here
    Template: twentytwelve
    */
    
    @import url("../twentytwelve/style.css");

    Then, I uploaded it onto my server:

    /Megans WordPress/wp-content/themes/twenty twelve child

    And then activated the theme through my wordpress dashboard.

    But, none of my code will work? The code will only work when i put it in my CSS Manager plugin?

    Any ideas as to why this isn't working would be greatly appreciated.

    Thanks!

  2. leejosepho
    Member
    Posted 1 year ago #

    Theme Name: Twentytwelve Child

    /Megans WordPress/wp-content/themes/twenty twelve child

    That might have to do with your theme name and the name of its folder not being the same, but I am not sure about that.

  3. mrmccarrin
    Member
    Posted 1 year ago #

    Thank you. I tried that, but it did not work.

  4. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    If you post a link to your site, someone can more likely help you with this question.

  5. mrmccarrin
    Member
    Posted 1 year ago #

    meganrmccarrin.com

  6. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    Looks like your child theme is not set up correctly - did you create a folder for the child theme? Is this the file structure you have:

    wp-content
                themes (directory where all themes are)
                    twentytwelve
                    twentytwelve-child
                        style.css

    Perhaps review: http://codex.wordpress.org/Child_Themes

  7. mrmccarrin
    Member
    Posted 1 year ago #

    Yes, that is the structure I have.

  8. mrmccarrin
    Member
    Posted 1 year ago #

    And, I have reviewed that link several times and I can't figure out what is wrong?

  9. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    That's what we are trying to figure out :).

    Did you use a plain text editor for making the style.css file?

    Is there anything else in the file besides what you posted above?

    What you posted above this:

    /Megans WordPress/wp-content/themes/twenty twelve child

    is not the same as this - which is what is visible on your site:

    http://meganrmccarrin.com/wp-content/themes/TwentytwelveChild/style.css

    Try taking the capital letters out of the child theme folder name.

  10. mrmccarrin
    Member
    Posted 1 year ago #

    I took the capital letters out. I saved this in Notepad under style.css and uploaded it:

    /*
    Theme Name: Twentytwelve Child
    Description: Child theme for the twentytwelve theme
    Author: Your name here
    Template: twentytwelve
    */

    @import url("../twentytwelve/style.css");

    Still not working.

  11. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    You can download a pre-made Twenty Twelve child theme from here. Tested and known to work. :-)

  12. mrmccarrin
    Member
    Posted 1 year ago #

    Thank you, but what does it mean if I try that and it doesn't work?

  13. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    Then post back and someone can continue helping you figure out what's going on.

  14. esmi
    Theme Diva & Forum Moderator
    Posted 1 year ago #

    If the downloadable child theme doesn't work, then there's an issue outside of the child theme itself - possibly in the parent theme or within the server's configuration.

  15. mrmccarrin
    Member
    Posted 1 year ago #

    It makes edits within the child theme, but they do not carry over to my twenty twelve theme?

  16. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    You don't have a child theme active at the moment. We can't help you unless you have that active.

    Also, theme settings and options don't carry over to a child theme, so you will have to redo those in the child theme.

  17. mrmccarrin
    Member
    Posted 1 year ago #

    It is active now.

    I meant that I madee changes in the Child Theme. The Changes show up in the Child theme, but do not show up in the Twenty Twelve theme when I switch over.

  18. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    That's not how a child theme works - if you are using a child theme, you only use that child theme - changes are not supposed to show up on a parent theme.

  19. mrmccarrin
    Member
    Posted 1 year ago #

    I see now. Thank you.

  20. WPyogi
    Volunteer Moderator
    Posted 1 year ago #

    BTW, it looks like it's set up and working fine - YAY!

  21. mrmccarrin
    Member
    Posted 1 year ago #

    It is working very well :) YAY!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags

No tags yet.