Make WordPress Core


Ignore:
Timestamp:
09/02/2013 09:20:56 PM (13 years ago)
Author:
lancewillett
Message:

Twenty Fourteen: add archive page templates, fix alignment bugs for archive headers, and use content-none.php for consistency. Props obenland, fixes #25181.

File:
1 edited

Legend:

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

    r25088 r25213  
    99get_header(); ?>
    1010
    11 <section id="primary" class="content-area">
    12     <div id="content" class="site-content" role="main">
     11    <section id="primary" class="content-area">
     12        <div id="content" class="site-content" role="main">
    1313
    14         <?php if ( have_posts() ) : ?>
     14            <?php if ( have_posts() ) : ?>
    1515
    16         <header class="page-header">
    17             <h1 class="page-title"><?php printf( __( 'Search Results for: %s', 'twentyfourteen' ), get_search_query() ); ?></h1>
    18         </header><!-- .page-header -->
     16            <header class="page-header">
     17                <h1 class="page-title"><?php printf( __( 'Search Results for: %s', 'twentyfourteen' ), get_search_query() ); ?></h1>
     18            </header><!-- .page-header -->
    1919
    20         <?php
    21                 while ( have_posts() ) :
    22                     the_post();
     20            <?php
     21                    while ( have_posts() ) :
     22                        the_post();
    2323
    24                     get_template_part( 'content', get_post_format() );
    25                 endwhile;
    26                 twentyfourteen_paging_nav();
     24                        get_template_part( 'content', get_post_format() );
     25                    endwhile;
     26                    twentyfourteen_paging_nav();
    2727
    28             else :
    29                 get_template_part( 'no-results', 'search' );
     28                else :
     29                    get_template_part( 'content', 'none' );
    3030
    31             endif;
    32         ?>
     31                endif;
     32            ?>
    3333
    34     </div><!-- #content -->
    35 </section><!-- #primary -->
     34        </div><!-- #content -->
     35    </section><!-- #primary -->
    3636
    3737<?php
Note: See TracChangeset for help on using the changeset viewer.