1. <?php
  2. /* ========== HEAD TITLE ========== */
  3. ?><title><?php
  4. if (weaver_getopt('ttw_hide_metainfo')) {
  5. wp_title(''); /* this is compatible with SEO plugins */
  6. } else {
  7. /*
  8. * Print the <title> tag based on what is being viewed.
  9. */
  10. global $page, $paged;
  11.  
  12. wp_title( '|', true, 'right' );
  13.  
  14. /* Add the blog name. */
  15. bloginfo( 'name' );
  16.  
  17. /* Add the blog description for the home/front page. */
  18. $site_description = get_bloginfo( 'description', 'display' );
  19. if ( $site_description && ( is_home() || is_front_page() ) )
  20. echo " | $site_description";
  21.  
  22. /* Add a page number if necessary: */
  23. if ( $paged >= 2 || $page >= 2 )
  24. echo ' | ' . sprintf( __( 'Page %s', WEAVER_TRANS ), max( $paged, $page ) );
  25. }
  26. ?></title>