content-none.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <?php
  2. /**
  3. * The template part for displaying a message that posts cannot be found.
  4. *
  5. * Learn more: http://codex.wordpress.org/Template_Hierarchy
  6. *
  7. * @package WordPress
  8. * @subpackage Twenty_Fifteen
  9. * @since Twenty Fifteen 1.0
  10. */
  11. ?>
  12. <section class="no-results not-found">
  13. <header class="page-header">
  14. <h1 class="page-title"><?php esc_html_e( 'Nothing Found', 'twentyfifteen' ); ?></h1>
  15. </header><!-- .page-header -->
  16. <div class="page-content">
  17. <?php if ( is_home() && current_user_can( 'publish_posts' ) ) : ?>
  18. <p><?php printf( esc_html__( 'Ready to publish your first post? <a href="%1$s">Get started here</a>.', 'twentyfifteen' ), esc_url( admin_url( 'post-new.php' ) ) ); ?></p>
  19. <?php elseif ( is_search() ) : ?>
  20. <p><?php esc_html_e( 'Sorry, but nothing matched your search terms. Please try again with some different keywords.', 'twentyfifteen' ); ?></p>
  21. <?php get_search_form(); ?>
  22. <?php else : ?>
  23. <p><?php esc_html_e( 'It seems we can&rsquo;t find what you&rsquo;re looking for. Perhaps searching can help.', 'twentyfifteen' ); ?></p>
  24. <?php get_search_form(); ?>
  25. <?php endif; ?>
  26. </div><!-- .page-content -->
  27. </section><!-- .no-results -->