• Resolved Que42

    (@que42)


    Hi everyone. I’m doing a child theme off of twenty twelve and having one bear of a time with one issue. On my main page I’m wrapping my content with a box shadow as in

    box-shadow: 5px 5px 5px #000000 inset;

    Using it on

    .site-content article {

    Looks great and wraps all the post content. That is until I go to the post page. There doesn’t seem to be any content wrapper that shows up on firebug, only the individual small parts. Could make due with them I guess but then the front page looks like dirt. Does anyone know if the post page has a post content wrapper I can use? One that will cover the content, content header and content footer?

    Thanks
    Que

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hi,
    Good to hear you are using a child theme, very smart. Suggest copying over the appropriate theme files and adding your own div to style with the box shadow. This way you can have it show up where and when you want.

    Here is some useful information: http://codex.ww.wp.xz.cn/Site_Architecture_1.5

    Theme files you will likely need to copy to the child theme folder and edit are:
    single.php – single post page, it may have a call to a content page
    page.php – normal page, it too may have a call inside to content page
    category.php
    archive.php
    search.php

    Post a link so we can see your masterpiece.

    Thread Starter Que42

    (@que42)

    Thanks Flash but I’m wondering if this is way out of my abilities. But what the heck. I found where I need it in page.php but don’t know how to implement it. Tried <div class=”que”> and a couple other things but to noby to get it right.

    get_header(); ?>
    ---------------NEED TO START .QUE HERE---------------
    	<div id="primary">
    		<div id="content" role="main">
    
    			<?php while ( have_posts() ) : the_post(); ?>
    
    				<?php get_template_part( 'content', get_post_format() ); ?>
    
    				<nav class="nav-single">
    					<h3 class="assistive-text"><?php _e( 'Post navigation', 'twentytwelve' ); ?></h3>
    					<span class="nav-previous"><?php previous_post_link( '%link', '<span class="meta-nav">' . _x( '&larr;', 'Previous post link', 'twentytwelve' ) . '</span> %title' ); ?></span>
    					<span class="nav-next"><?php next_post_link( '%link', '%title <span class="meta-nav">' . _x( '&rarr;', 'Next post link', 'twentytwelve' ) . '</span>' ); ?></span>
    				</nav><!-- .nav-single -->
    
    			<?php endwhile; // end of the loop. ?>
    
    		</div><!-- #content -->
    	</div><!-- #primary -->
    ---------NEED TO STOP .QUE HERE--------------
    <?php get_footer(); ?>

    And added this to style.css

    .que {
    		box-shadow: inset 5px 5px 5px #000;
    	}

    Where did I go wrong?

    I got my start with “what the heck”. Good to see your using a tried and true method of learning 🙂

    You didn’t create a div to hold the content in a container that would have a box shadow.

    get_header(); ?>
    <!-- -------------NEED TO START .QUE HERE------------- -->
    <div class="que">
    	<div id="primary">
    		<div id="content" role="main">
    			<?php while ( have_posts() ) : the_post(); ?>
    
    				<?php get_template_part( 'content', get_post_format() ); ?>
    
    				<nav class="nav-single">
    					<h3 class="assistive-text"><?php _e( 'Post navigation', 'twentytwelve' ); ?></h3>
    					<span class="nav-previous"><?php previous_post_link( '%link', '<span class="meta-nav">' . _x( '←', 'Previous post link', 'twentytwelve' ) . '</span> %title' ); ?></span>
    					<span class="nav-next"><?php next_post_link( '%link', '%title <span class="meta-nav">' . _x( '→', 'Next post link', 'twentytwelve' ) . '</span>' ); ?></span>
    				</nav><!-- .nav-single -->
    
    			<?php endwhile; // end of the loop. ?>
    
    		</div><!-- #content -->
    	</div><!-- #primary -->
    </div><!-- #que -->
    <?php get_footer(); ?>

    I changed you code by adding a div with the class .que, based upon your markup. I don’t know if that is going to give you the results you want.

    I generally find myself making good guesses in a situation like this then experimenting until I either figure it out or move on to plan b.

    Thread Starter Que42

    (@que42)

    Hey Thanks Flash

    I’d tried the <div class=”que”> with no result but hearing that it was right from someone who knows their stuff made me look elsewhere and it was in the style sheet. Success gives me the confidence to try harder stuff. Pray for me my fellow man lol.

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Post content wrapper’ is closed to new replies.