Make WordPress Core


Ignore:
Timestamp:
08/14/2013 04:38:01 PM (12 years ago)
Author:
lancewillett
Message:

Twenty Fourteen: first pass at matching code standards achieved with Twenty Thirteen development. See #24858, props obenland.

File:
1 edited

Legend:

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

    r24832 r25021  
    1515get_header(); ?>
    1616
    17 <?php if ( is_front_page() ) : ?>
    18 
    19     <div class="front-page-content-wrapper">
    20         <div class="front-page-content-main">
    21 
    22             <?php if ( twentyfourteen_has_featured_posts() ) : ?>
    23                 <?php get_template_part( 'featured-content' ); ?>
    24             <?php endif; ?>
    25 
    26             <div class="front-page-content-area clearfix">
    27 
    28                 <div id="primary" class="content-area no-sidebar">
    29                     <div id="content" class="site-content" role="main">
    30                     <?php
    31                         if ( have_posts() ) :
    32                             while ( have_posts() ) :
    33                                 the_post();
    34                                 twentyfourteen_get_template_part();
    35                             endwhile;
    36 
    37                             twentyfourteen_content_nav( 'nav-below' );
    38                         else :
    39                             get_template_part( 'no-results', 'index' );
    40                         endif;
    41                     ?>
    42                     </div><!-- #content .site-content -->
    43                 </div><!-- #primary .content-area -->
    44 
    45                 <?php get_template_part( 'recent-formatted-posts' ); ?>
    46 
    47             </div><!-- .front-page-content-area -->
    48 
    49         </div><!-- .front-page-content-main -->
    50     </div><!-- .front-page-content-wrapper -->
    51 
    52     <?php get_sidebar(); ?>
    53 
    54 <?php else : ?>
    55 
    5617    <div id="primary" class="content-area">
    5718        <div id="content" class="site-content" role="main">
    5819
    59         <?php if ( have_posts() ) : ?>
     20        <?php
     21            if ( have_posts() ) :
     22                while ( have_posts() ) :
     23                    the_post();
    6024
    61             <?php while ( have_posts() ) : the_post(); ?>
     25                    twentyfourteen_get_template_part();
     26                endwhile;
     27                twentyfourteen_content_nav( 'nav-below' );
    6228
    63                 <?php twentyfourteen_get_template_part(); ?>
     29            else :
     30                get_template_part( 'no-results', 'index' );
    6431
    65             <?php endwhile; ?>
     32            endif;
     33        ?>
    6634
    67             <?php twentyfourteen_content_nav( 'nav-below' ); ?>
     35        </div><!-- #content -->
     36    </div><!-- #primary -->
    6837
    69         <?php else : ?>
    70 
    71             <?php get_template_part( 'no-results', 'index' ); ?>
    72 
    73         <?php endif; ?>
    74 
    75         </div><!-- #content .site-content -->
    76     </div><!-- #primary .content-area -->
    77 
    78     <?php get_sidebar( 'content' ); ?>
    79 
    80     <?php get_sidebar(); ?>
    81 
    82 <?php endif; // is_front_page() check ?>
    83 
    84 <?php get_footer(); ?>
     38<?php
     39get_sidebar( 'content' );
     40get_sidebar();
     41get_footer();
Note: See TracChangeset for help on using the changeset viewer.