关于Typecho模糊搜索含有空格特殊符号的功能优化

听群友所说,我才发现Typecho在搜索含有空格或特殊符号的关键词时会搜不到,当时还比较迷糊,然后随后百度了一下,其实网上已经有了解决方法:

只需把var/Widget/Archive.php的searchHandle函数中$keywords = $this->request->filter('url', 'search')->keywords;替换为:$keywords = $this->request->keywords;即可进行Typecho模糊搜索,至于细节方面没有过多测试,此方法仅供参考。

发表回复

您的邮箱地址不会被公开。 必填项已用 * 标注