ThemeShaper Forums » Thematic

[closed]

Rearrange Container, Primary and Secondary

(7 posts)
  • Started 2 years ago by lance1572
  • Latest reply from danromanchik
  • This topic is resolved
  1. lance1572
    Member

    Hi all....back again! Happy New Year! I'm on my seventh Thematic Child theme build and loving it! but I'm kind of stuck - should know this stuff by now.. :(

    Wondering how i can re-arrange the divs (Container, Primary and Sidebar)

    I'd like to make the structure as follows:

    Primary div
    Container div
    Secondary div

    Right now it's

    Container div
    Primary
    Secondary

    I assuming I would have to target the thematic_sidebar but stuck on how to target the primary and secondary specifically! Just need to move the secondary div above the container. Seems it would be easy but I cannot find any info. Appreciate any help!

    thank you!!!!
    Lance

    Posted 2 years ago #
  2. lance1572
    Member

    Fixed: Found this and edited to suit.

    function kia_move_primary_aside($content) {
    $content['Primary Aside']['action_hook'] = 'thematic_abovecontainer';
    $content['Primary Aside']['priority'] = 11; //so it comes after brandingclose
    return $content;
    }
    add_filter('thematic_widgetized_areas','kia_move_primary_aside');

    It works as far as placement but there is no content in the content div now.

    Posted 2 years ago #
  3. do you really need to change the markup? you can get the primary column to appear to the left of container. check out the 3 column layout.

    Posted 2 years ago #
  4. lance1572
    Member

    I did and while the CSS is awesome for SEO I really would just love to know how to move that primary out of the container and into main. The -margins dont really work with the layout I have to reconstruct. I'll keep the 3 col layout that I am using but just wanted to know if it was possible. I have to actually recreate a site that is only 760 wide :(

    Posted 2 years ago #
  5. function kia_move_primary_aside($content) {
    	$content['Primary Aside']['action_hook'] = 'thematic_abovecontainer';
    	return $content;
    }
    add_filter('thematic_widgetized_areas','kia_move_primary_aside');

    makes the markup

    <div id="primary" class="aside main-aside">
    <div id="container">
    <div id="secondary" class="aside main-aside">

    just like you thought. not sure what the problem is, b/c i have content in my #content div. perhaps you've got some improperly closed markup in a text widget?

    no reason the 3 col layout can't be adapted down to 760px either. and idk what you have in the primary div, but typically it is better for SEO to have the content before the widget areas. just some thoughts.

    Posted 2 years ago #
  6. lance1572
    Member

    thank you Helga! i must have some problem with my CSS. I went back to the 3 col layout and adjusted. it's fine. But thank you I might need this in the future ;) thank you thank you as always!

    Posted 2 years ago #
  7. danromanchik
    Member

    Thanks for this timely posting. I'm working on a site that wants to have the secondary aside on the left side of the container. Here's the code for that:

    //move secondary header to left of container
    function kia_move_secondary_aside($content) {
    	$content['Secondary Aside']['action_hook'] = 'thematic_abovecontainer';
    	return $content;
    }
    add_filter('thematic_widgetized_areas','kia_move_secondary_aside');
    Posted 2 years ago #

RSS feed for this topic

Topic Closed

This topic has been closed to new replies.