fix: problem with two identical id dom

pull/292/head
Seaton Jiang 2020-09-27 08:14:48 +08:00
parent 6c2e6eb0bb
commit 2fc503fedc
No known key found for this signature in database
GPG Key ID: C1086BAE716FF138
2 changed files with 4 additions and 4 deletions

View File

@ -3,7 +3,7 @@
* 主题页脚
* @author Seaton Jiang <seaton@vtrois.com>
* @license MIT License
* @version 2020.04.12
* @version 2020.09.27
*/
?>
<div class="k-footer">
@ -24,7 +24,7 @@
<div class="search">
<span class="kicon i-find"></span>
<form class="search-form" role="search" method="get" action="<?php echo home_url('/'); ?>">
<input type="text" name="s" id="search" placeholder="<?php _e('搜点什么呢?', 'kratos'); ?>" style="display:none"/>
<input type="text" name="s" id="search-footer" placeholder="<?php _e('搜点什么呢?', 'kratos'); ?>" style="display:none"/>
</form>
</div>
</div>

View File

@ -3,7 +3,7 @@
* 侧栏小工具
* @author Seaton Jiang <seaton@vtrois.com>
* @license MIT License
* @version 2020.08.03
* @version 2020.09.27
*/
// 添加小工具
@ -78,7 +78,7 @@ class widget_search extends WP_Widget {
if ( $title ) {
echo '<div class="title">'. $title .'</div>';
}
echo '<div class="item"> <form role="search" method="get" id="searchform" class="searchform" action="'. home_url('/') .'"> <div class="input-group mt-2 mb-2"> <input type="text" name="s" id="search" class="form-control" placeholder="'. __('搜点什么呢?', 'kratos') .'"> <div class="input-group-append"> <button class="btn btn-primary btn-search" type="submit" id="searchsubmit">'. __('搜索', 'kratos') .'</button> </div> </div> </form>';
echo '<div class="item"> <form role="search" method="get" id="searchform" class="searchform" action="'. home_url('/') .'"> <div class="input-group mt-2 mb-2"> <input type="text" name="s" id="search-widgets" class="form-control" placeholder="'. __('搜点什么呢?', 'kratos') .'"> <div class="input-group-append"> <button class="btn btn-primary btn-search" type="submit" id="searchsubmit">'. __('搜索', 'kratos') .'</button> </div> </div> </form>';
echo '</div></div>';
}