footer.php 9.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200
  1. <?php
  2. /**
  3. * The template for displaying the footer.
  4. *
  5. * Contains the closing of the #content div and all content after.
  6. *
  7. * @link https://developer.wordpress.org/themes/basics/template-files/#template-partials
  8. *
  9. * @package Sakura
  10. */
  11. $reception_background = iro_opt('reception_background');
  12. ?>
  13. </div><!-- #content -->
  14. <?php
  15. comments_template('', true);
  16. ?>
  17. </div><!-- #page Pjax container-->
  18. <footer id="colophon" class="site-footer" role="contentinfo">
  19. <div class="site-info" theme-info="Sakurairo v<?php echo IRO_VERSION; ?>">
  20. <div class="footertext">
  21. <div class="img-preload">
  22. <img alt="loading_svg" src="<?php echo iro_opt('load_nextpage_svg'); ?>"><!-- 加载下一部分圈圈 -->
  23. </div>
  24. <div class="sakura-icon" style="width:max-content;height:max-content;margin: auto;">
  25. <svg width="30px" height="30px" t="1682340134496" class="sakura-svg" viewBox="0 0 1049 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="5240"><path d="M525.58396628 573.34694353s268.83106938-2.62915481 309.36387092 193.24287089l-76.46458293 21.90962291 12.92667757 84.13295086a214.05701289 214.05701289 0 0 1-96.84053193-4.82011663A224.79272784 224.79272784 0 0 1 525.58396628 578.38615666z" fill="#EE9ca7" p-id="5241"></path><path d="M552.75189802 512.4381922s131.45773592-233.7756732 321.63325979-170.89505575L854.2283053 418.66500728l79.31283344 30.89256828a215.59068679 215.59068679 0 0 1-52.58309388 81.50379604 224.57363215 224.57363215 0 0 1-325.35789552-14.67944718z" fill="#EE9ca7" p-id="5242"></path><path d="M508.49446078 494.0341093S317.00435871 306.48774025 426.77156822 139.31731943l69.4535037 38.78003191L547.4935884 109.30113636a214.05701289 214.05701289 0 0 1 65.72886796 71.86356201 225.01182435 225.01182435 0 0 1-98.37420505 310.67844912z" fill="#EE9ca7" p-id="5243"></path><path d="M473.21996809 525.58396628S242.2925454 661.64272234 109.30113636 512.4381922l55.43134521-57.18411482-53.45947909-65.72886795a213.61882069 213.61882069 0 0 1 86.32391269-43.81924506 224.79272784 224.79272784 0 0 1 274.527572 175.27698099z" fill="#EE9ca7" p-id="5244"></path><path d="M481.76472043 566.55496s72.0826585 258.31445093-106.4807652 348.14390364l-40.31370582-68.13892627-78.21735252 34.17901099a212.30424328 212.30424328 0 0 1-20.15685331-94.64956933 224.57363215 224.57363215 0 0 1 241.00584894-219.09622602z" fill="#EE9ca7" p-id="5245"></path></svg>
  26. </div>
  27. <p style="color: #666666;"><?php echo iro_opt('footer_info', ''); ?></p>
  28. </div>
  29. <div class="footer-device function_area">
  30. <?php if(iro_opt('footer_yiyan')){ ?>
  31. <p id="footer_yiyan"></p>
  32. <?php } ?>
  33. <span style="color: #b9b9b9;">
  34. <?php /* 能保留下面两个链接吗?算是我一个小小的心愿吧~ */ ?>
  35. <?php if (iro_opt('footer_load_occupancy', 'true')): ?>
  36. <?php printf(
  37. _x( 'Load Time %.3f seconds | %d Query | RAM Usage %.2f MB ', 'footer load occupancy', 'sakurairo' ),
  38. timer_stop( 0, 3 ),get_num_queries(),memory_get_peak_usage() / 1024 / 1024);
  39. ?>
  40. <?php endif; ?>
  41. <?php if (iro_opt('footer_upyun', 'true')): ?>
  42. 本网站由 <a href="https://www.upyun.com/?utm_source=lianmeng&utm_medium=referral" target="_blank"> <img alt="upyun-logo" src="https://s.nmxc.ltd/sakurairo_vision/@2.6/options/upyun_logo.webp" style="display:inline-block;vertical-align:middle;width:60px;height:30px;"/> 提供 CDN 加速 / 云存储 服务
  43. <?php endif; ?>
  44. <br>
  45. <a href="https://github.com/mirai-mamori/Sakurairo" rel="noopener" target="_blank" id="site-info" >Theme Sakurairo</a><a href="https://docs.fuukei.org/" rel="noopener" target="_blank" id="site-info" > by Fuukei</a>
  46. </span>
  47. </div>
  48. </div><!-- .site-info -->
  49. </footer><!-- #colophon -->
  50. </section><!-- #section -->
  51. <!-- m-nav-center -->
  52. <div id="mo-nav">
  53. <div class="m-avatar">
  54. <?php
  55. $personal_avatar = iro_opt('personal_avatar');
  56. $iro_logo = iro_opt('iro_logo');
  57. $ava = iro_opt('personal_avatar') ? $personal_avatar: ($iro_logo ?: iro_opt('vision_resource_basepath','https://s.nmxc.ltd/sakurairo_vision/@2.6/').'series/avatar.webp'); ?>
  58. <img alt="m-avatar" src="<?php echo $ava ?>">
  59. </div>
  60. <div class="m-search">
  61. <form class="m-search-form" method="get" action="<?php echo home_url(); ?>" role="search">
  62. <input class="m-search-input" type="search" name="s" placeholder="<?php _e('Search...', 'sakurairo') /*搜索...*/?>" required>
  63. </form>
  64. </div>
  65. <?php wp_nav_menu( array( 'depth' => 2, 'theme_location' => 'primary', 'container' => false ) ); ?>
  66. </div><!-- m-nav-center end -->
  67. <button id="moblieGoTop" title="<?=__('Go to top','sakurairo');?>"><i class="fa-solid fa-caret-up fa-lg"></i></button>
  68. <button id="changskin" title="<?=__('Control Panel','sakurairo');?>" ><i class="fa-solid fa-compass-drafting fa-lg fa-flip" style="--fa-animation-duration: 3s;"></i></button>
  69. <!-- search start -->
  70. <form class="js-search search-form search-form--modal" method="get" action="<?php echo home_url(); ?>" role="search">
  71. <div class="search-form__inner">
  72. <?php if(iro_opt('live_search')){ ?>
  73. <div class="micro">
  74. <input id="search-input" class="text-input" type="search" name="s" placeholder="<?php _e('Want to find something?', 'sakurairo') /*想要找点什么呢*/?>" required>
  75. </div>
  76. <div class="ins-section-wrapper">
  77. <a id="Ty" href="#"></a>
  78. <div class="ins-section-container" id="PostlistBox"></div>
  79. </div>
  80. <?php }else{ ?>
  81. <div class="micro">
  82. <p class="micro mb-"><?php _e('Want to find something?', 'sakurairo') /*想要找点什么呢*/?></p>
  83. <input class="text-input" type="search" name="s" placeholder="<?php _e('Search', 'sakurairo') ?>" required>
  84. </div>
  85. <?php } ?>
  86. </div>
  87. <div class="search_close"></div>
  88. </form>
  89. <!-- search end -->
  90. <?php wp_footer(); ?>
  91. <div class="skin-menu no-select">
  92. <?php if (iro_opt('sakura_widget')) : ?>
  93. <aside id="iro-widget" class="widget-area" role="complementary">
  94. <div class="sakura_widget">
  95. <?php if (function_exists('dynamic_sidebar') && dynamic_sidebar('sakura_widget')) : endif; ?>
  96. </div>
  97. </aside>
  98. <?php endif; ?>
  99. <?php if (iro_opt('widget_shuo', 'true')) : ?>
  100. <?php
  101. $args = array(
  102. 'post_type' => 'shuoshuo',
  103. 'post_status' => 'publish',
  104. 'posts_per_page' => 1
  105. );
  106. $shuoshuo_query = new WP_Query($args);
  107. ?>
  108. <?php while ($shuoshuo_query->have_posts()) : $shuoshuo_query->the_post(); ?>
  109. <div class="footer-shuo">
  110. <p><?php echo strip_tags(get_the_content()); ?></p>
  111. <p class="footer-shuotime"><i class="fa-regular fa-clock"></i> <?php the_time('Y/n/j G:i'); ?></p>
  112. </div>
  113. <?php endwhile; ?>
  114. <?php wp_reset_postdata(); ?>
  115. <?php endif; ?>
  116. <div class="theme-controls row-container">
  117. <?php if (iro_opt('widget_daynight', 'true')): ?>
  118. <ul class="menu-list">
  119. <li id="white-bg" title="<?=__('Light Mode','sakurairo');?>" >
  120. <i class="fa-solid fa-display fa-sm"></i>
  121. </li><!--Default-->
  122. <li id="dark-bg" title="<?=__('Dark Mode','sakurairo');?>" >
  123. <i class="fa-regular fa-moon"></i>
  124. </li><!--Night-->
  125. </ul>
  126. <?php endif; ?>
  127. <?php if(array_search(1, $reception_background) !== false): ?>
  128. <ul class="menu-list" title="<?=__('Toggle Page Background Image','sakurairo');?>">
  129. <?php
  130. $bgIcons = [
  131. ['heart_shaped', 'fa-regular fa-heart', 'diy1-bg'],
  132. ['star_shaped', 'fa-regular fa-star', 'diy2-bg'],
  133. ['square_shaped', 'fa-brands fa-delicious', 'diy3-bg'],
  134. ['lemon_shaped', 'fa-regular fa-lemon', 'diy4-bg']
  135. ];
  136. foreach ($bgIcons as $bgIcon) {
  137. if ($reception_background[$bgIcon[0]] == '1') {
  138. echo '<li id="' . $bgIcon[2] . '">';
  139. echo '<i class="' . $bgIcon[1] . '"></i>';
  140. echo '</li>';
  141. }
  142. }
  143. ?>
  144. </ul>
  145. <?php endif; ?>
  146. <?php if (iro_opt('widget_font', 'true')): ?>
  147. <div class="font-family-controls row-container">
  148. <button type="button" class="control-btn-serif selected" title="<?=__('Switch To Font A','sakurairo');?>" data-name="serif">
  149. <i class="fa-solid fa-font fa-lg"></i>
  150. </button>
  151. <button type="button" class="control-btn-sans-serif" title="<?=__('Switch To Font B','sakurairo');?>" data-name="sans-serif">
  152. <i class="fa-solid fa-bold fa-lg"></i>
  153. </button>
  154. </div>
  155. <?php endif; ?>
  156. </div>
  157. </div>
  158. <?php if (iro_opt('aplayer_server') != 'off'): ?>
  159. <div id="aplayer-float" style="z-index: 100;"
  160. class="aplayer"
  161. data-id="<?php echo iro_opt('aplayer_playlistid', ''); ?>"
  162. data-server="<?php echo iro_opt('aplayer_server'); ?>"
  163. data-preload="<?php echo iro_opt('aplayer_preload'); ?>"
  164. data-type="playlist"
  165. data-fixed="true"
  166. data-order="<?php echo iro_opt('aplayer_order'); ?>"
  167. data-volume="<?php echo iro_opt('aplayer_volume', ''); ?>"
  168. data-theme="<?php echo iro_opt('theme_skin'); ?>">
  169. </div>
  170. <?php endif; ?>
  171. <!-- 首页波浪特效 -->
  172. <?php if (iro_opt('wave_effects', 'true')): ?>
  173. <link rel="stylesheet" href="<?php global $shared_lib_basepath;echo $shared_lib_basepath?>/css/wave.css">
  174. <?php endif; ?>
  175. <?php
  176. echo iro_opt('footer_addition', '');
  177. ?>
  178. </body>
  179. <!-- Particles动效 -->
  180. <?php if (iro_opt('particles_effects', 'true')): ?>
  181. <style>
  182. #particles-js {
  183. width: 100%;
  184. height: 100%;
  185. position: fixed;
  186. left: 0;
  187. right: 0;
  188. top: 0;
  189. bottom: 0;
  190. z-index: -1;
  191. }
  192. </style>
  193. <div id="particles-js"></div>
  194. <script type="application/json" id="particles-js-cfg"><?=iro_opt('particles_json','')?></script>
  195. <?php endif; ?>
  196. </html>