Making WordPress.org


Ignore:
Timestamp:
11/16/2018 08:35:54 PM (7 years ago)
Author:
coffee2code
Message:

Breathe: Customize search results template for handbook search results.

  • Prevents display of author Gravatar and name
  • Prevents display of post date
  • Displays post excerpts instead of full content
  • Customizes page header to indicate results are just from the handbook
  • Based off copy of p2-breathe's content-search.php
File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/themes/pub/wporg-breathe/search.php

    r5238 r7859  
    1313
    1414    <section id="primary" class="content-area">
    15         <div id="content" class="site-content" role="main">
     15        <div id="<?php echo $is_handbook ? 'handbook-content' : 'content'; ?>" class="site-content" role="main">
    1616
    1717        <?php if ( have_posts() ) : ?>
     
    1919            <header class="page-header">
    2020                <h1 class="page-title">
    21                     <?php printf( __( 'Search Results for: %s', 'wporg-breathe' ), '<span>' . get_search_query() . '</span>' ); ?>
     21                    <?php if ( wporg_is_handbook() ) {
     22                        printf( __( 'Handbook Search Results for: %s', 'wporg-breathe' ), '<span>' . get_search_query() . '</span>' );
     23                    } else {
     24                        printf( __( 'Search Results for: %s', 'wporg-breathe' ), '<span>' . get_search_query() . '</span>' );
     25                    } ?>
    2226
    2327                    <span class="controls">
Note: See TracChangeset for help on using the changeset viewer.