WordPress.org

Ready to get started?Download WordPress

Forums

Moving header after child theme installed (twentytwelve) (2 posts)

  1. topstocks
    Member
    Posted 1 year ago #

    As a very new WP user, I was feeling pretty good that I managed to move the header in twentytwelve (to above the menu).

    I then learned about child themes and the importance of. (Man could I go on about that. Ridiculous in this day and age that you have to muck around like that. Software exists to make life easier! There should be one button to press, and that's it!)

    But anyway........So I started from scracth (with a fresh twentytwelve theme) and I managed to learn and successfully implement a child theme. Yay!

    But I now have no idea where to go to do the header change. All the things (in css world) that were there when I was playing in the main twenty twelve theme don't seem to be around anymore?

  2. Good Guy
    Member
    Posted 1 year ago #

    You do exactly the same thing as you did before the child theme was used except that this time you use the files in the child theme. If there aren't any then you create them one by one. you don't have to copy any of the code from the original themes. You only supplement with the changes. For example your css file might look something like this:

    /*
    Theme Name:     2012-Child
    Description:    Child theme for twenty-twelve theme from WordPress.org and Automattic
    Author:         WP-Novice
    Template:       twentytwelve
    
    (optional values you can add: Theme URI, Author URI, Version)
    */
    
    @import url("../twentytwelve/style.css");
    /*-- move sidebar to the left --*/
    @media screen and (min-width: 600px) {
        .site-content {
            float: right;
        }
        .widget-area {
            float: left;
        }
    }
    
    /* for IE8 and IE7 ----------------*/
    .ie .site-content {
        float: right;
    }
    .ie .widget-area {
        float: left;
    /**********************************************************************/

    Some of the code are mine I have created to change the layout.

    Same thing applies with footer.php or header.php or whatever.

Topic Closed

This topic has been closed to new replies.

About this Topic