Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

点击搜索焦点问题 #16

Open
cxg83843652 opened this issue Jul 21, 2022 · 1 comment
Open

点击搜索焦点问题 #16

cxg83843652 opened this issue Jul 21, 2022 · 1 comment

Comments

@cxg83843652
Copy link

$('#search > form > input[type="search"]').focus(); 似乎不起作用

@cxg83843652
Copy link
Author

自己提交的问题自己回答

 // 文件 assets/js/lolimeow.js 
 // $('#search > form > input[type="search"]').focus();  // 修改为
 $('#searchBtn').focus();
 // 文件 footer.php
<input type="search" name="s" value="<?php echo htmlspecialchars($s) ?>" placeholder="输入搜索关键词..." /></div> // 修改为
<input type="search" id="searchBtn" name="s" value="<?php echo htmlspecialchars($s) ?>" placeholder="输入搜索关键词..." /></div>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant