header.php 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. <!DOCTYPE HTML>
  2. <html>
  3. <!--
  4. ╔╗
  5. ║║
  6. ╔══╦══╣║╔══╦╗╔╦══╗╔══╦══╦╗╔╗
  7. ║══╣╔╗║║║╔╗║╚╝║╔╗║║╔═╣╔╗║╚╝║
  8. ╠══║╚╝║╚╣╚╝║║║║╚╝╠╣╚═╣╚╝║║║║
  9. ╚══╩══╩═╩══╩╩╩╣╔═╩╩══╩══╩╩╩╝
  10. ║║
  11. ╚╝
  12. -->
  13. <head>
  14. <meta charset="UTF-8">
  15. <meta http-equiv="X-UA-Compatible" content="IE=10,IE=9,IE=8">
  16. <meta name="theme-color" content="#1e90ff">
  17. <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0">
  18. <title><?php wp_title('|', true, 'right'); echo get_option('blogname'); if (is_home ()) echo " | ".get_option('blogdescription'); if ($paged > 1) echo '-Page ', $paged; ?></title>
  19. <?php
  20. $sr_1 = 0; $sr_2 = 0; $commenton = 0;
  21. if( dopt('d_sideroll_b') ){
  22. $sr_1 = dopt('d_sideroll_1');
  23. $sr_2 = dopt('d_sideroll_2');
  24. }
  25. if( is_singular() ){
  26. if( comments_open() ) $commenton = 1;
  27. }
  28. ?>
  29. <script>
  30. window._deel = {name: '<?php bloginfo('name') ?>',url: '<?php echo get_bloginfo("template_url") ?>', ajaxpager: '<?php echo dopt('d_ajaxpager_b') ?>', commenton: <?php echo $commenton ?>, roll: [<?php echo $sr_1 ?>,<?php echo $sr_2 ?>]}
  31. </script>
  32. <?php
  33. //49分类不被搜索引擎收录
  34. if (!is_home() && in_category('49') ){
  35. echo '<meta name="robots" content="noindex,nofollow" />';
  36. }
  37. ?>
  38. <?php
  39. wp_head();
  40. if( dopt('d_headcode_b') ) echo dopt('d_headcode'); ?>
  41. <link rel="shortcut icon" href="<?php echo get_stylesheet_directory_uri(); ?>/favicon.ico" />
  42. <!--[if lt IE 9]><script src="<?php bloginfo('template_url'); ?>/js/html5.js"></script><![endif]-->
  43. <!--<link type="text/css" rel="stylesheet" href="/font-awesome/css/font-awesome.css">-->
  44. <script src="/custom/duoshuo-ua/dist/duoshuo-ua-with-css-formated.min.js"></script>
  45. <script>var duoshuoQuery={short_name:'miles',myIds:[1637666]};</script>
  46. </head>
  47. <body <?php body_class(); ?>>
  48. <header id="header" class="header">
  49. <div class="container-inner">
  50. <div class="yusi-logo">
  51. <a href="/">
  52. <h1>
  53. <span class="yusi-mono"><?php bloginfo('name'); ?></span>
  54. <span class="yusi-bloger"><?php bloginfo('description'); ?></span>
  55. </h1>
  56. </a>
  57. </div>
  58. </div>
  59. <div id="nav-header" class="navbar">
  60. <ul class="nav">
  61. <?php echo str_replace("</ul></div>", "", ereg_replace("<div[^>]*><ul[^>]*>", "", wp_nav_menu(array('theme_location' => 'nav', 'echo' => false)) )); ?>
  62. <li style="float:right;">
  63. <div class="toggle-search"><i class="fa fa-search"></i></div>
  64. <div class="search-expand" style="display: none;"><div class="search-expand-inner"><form method="get" class="searchform themeform" onsubmit="location.href='<?php echo home_url('/search/'); ?>' + encodeURIComponent(this.s.value).replace(/%20/g, '+'); return false;" action="/"><div> <input type="ext" class="search" name="s" onblur="if(this.value=='')this.value='search...';" onfocus="if(this.value=='search...')this.value='';" value="search..."></div></form></div></div>
  65. </li>
  66. </ul>
  67. </div>
  68. </div>
  69. </header>
  70. <section class="container"><div class="speedbar">
  71. <?php
  72. if( dopt('d_sign_b') ){
  73. global $current_user;
  74. get_currentuserinfo();
  75. $uid = $current_user->ID;
  76. $u_name = get_user_meta($uid,'nickname',true);
  77. ?>
  78. <div class="pull-right">
  79. <?php if(is_user_logged_in()){echo '<i class="fa fa-user"></i> '.$u_name.' &nbsp; '; echo ' &nbsp; &nbsp; <i class="fa fa-power-off"></i> ';}else{echo '<i class="fa fa-user"></i> ';}; wp_loginout(); ?>
  80. </div>
  81. <?php } ?>
  82. <div class="toptip"><strong class="text-success"><i class="fa fa-volume-up"></i> </strong> <?php echo dopt('d_tui'); ?></div>
  83. </div>
  84. <?php if( dopt('d_adsite_01_b') ) echo '<div class="banner banner-site">'.dopt('d_adsite_01').'</div>'; ?>