加截中...

pbootcms如何显示按文章内容搜索,而不是搜索标题


pbootcms如何显示按文章内容搜索,而不是搜索标题

首先要在搜索代码里加上:

<input type="hidden" name="field" value="content" >

参考如下:

<form action="{pboot:scaction}" method="get">

    关键字:<input type="text" name="keyword" >

    <input type="hidden" name="field" value="content" >

    <button type="submit">搜索</button>

</form>
 


然后到搜索页面:search.html里面找到搜索结果的代码,加上代码:

value="title|content"

如下图:

1-22022P95GV18.png



在线客服
服务热线

服务热线

13648088499

微信咨询
二维码
返回顶部