Make WordPress Core


Ignore:
Timestamp:
09/20/2013 06:21:30 PM (12 years ago)
Author:
lancewillett
Message:

Twenty Fourteen: first pass at improving responsive patterns and allowing for a full-width layout when no secondary sidebar is present. Props iamtakashi, see #25332.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-content/themes/twentyfourteen/front-page.php

    r25213 r25519  
    99get_header(); ?>
    1010
    11     <div class="front-page-content-wrapper">
    12         <div class="front-page-content-main">
     11<div class="front-page-content-wrapper">
    1312
    14             <?php if ( twentyfourteen_has_featured_posts() ) : ?>
    15                 <?php get_template_part( 'featured-content' ); ?>
    16             <?php endif; ?>
     13    <?php
     14        if ( twentyfourteen_has_featured_posts() )
     15            get_template_part( 'featured-content' );
     16    ?>
    1717
    18             <div class="front-page-content-area">
     18        <div id="primary" class="content-area no-sidebar">
     19            <div id="content" class="site-content" role="main">
     20            <?php
     21                if ( have_posts() ) :
     22                    while ( have_posts() ) :
     23                        the_post();
    1924
    20                 <div id="primary" class="content-area no-sidebar">
    21                     <div id="content" class="site-content" role="main">
    22                     <?php
    23                         if ( have_posts() ) :
    24                             while ( have_posts() ) :
    25                                 the_post();
     25                        get_template_part( 'content', get_post_format() );
    2626
    27                                 get_template_part( 'content', get_post_format() );
     27                        comments_template();
     28                    endwhile;
     29                    twentyfourteen_paging_nav();
    2830
    29                                 comments_template();
    30                             endwhile;
    31                             twentyfourteen_paging_nav();
     31                else :
     32                    get_template_part( 'content', 'none' );
    3233
    33                         else :
    34                             get_template_part( 'content', 'none' );
     34                endif;
     35            ?>
     36            </div><!-- #content .site-content -->
     37        </div><!-- #primary .content-area -->
    3538
    36                         endif;
    37                     ?>
    38                     </div><!-- #content .site-content -->
    39                 </div><!-- #primary .content-area -->
     39        <?php get_sidebar( 'ephemera' ); ?>
    4040
    41                 <?php get_sidebar( 'ephemera' ); ?>
    42 
    43             </div><!-- .front-page-content-area -->
    44 
    45         </div><!-- .front-page-content-main -->
    46     </div><!-- .front-page-content-wrapper -->
     41</div><!-- .front-page-content-wrapper -->
    4742
    4843<?php
Note: See TracChangeset for help on using the changeset viewer.