联系官方销售客服
1835022288
028-61286886
怎么使用:模块搜索伪静态设置
为什么按照教程修改了,搜索还是动态页面啊,详细请看下面图片。
<?php /** * URL解析规则 * 例如: 114.html 对应 index.php?s=demo&c=show&id=114 * 可以解析: "114.html" => 'index.php?s=demo&c=show&id=114', * 动态id解析: "([0-9]+).html" => 'index.php?s=demo&c=show&id=$1', */ return [ "sitemap.xml" => "index.php?s=sitemap&c=home&m=xml", // 地图规则 "sitemap.txt" => "index.php?s=sitemap", // 地图规则 "author\/(.+)/\([0-9]+)\.html" => "index.php?s=tag&name=$1&page=$2", // tag插件分页 "author\/(.+)\.html" => "index.php?s=tag&name=$1", // tag插件 "author\/([0-9]+)" => "index.php?s=tag&page=$1", // tag插件聚合首页分页 "author" => "index.php?s=tag", // tag插件聚合首页 // 共享栏目---解析规则----开始 "([A-za-z0-9 \-\_]+)\/([0-9]+)" => "index.php?c=category&dir=$1&page=$2", //【共享栏目】模块栏目列表(分页)({dirname}/{page}/) "([A-za-z0-9 \-\_]+)" => "index.php?c=category&dir=$1", //【共享栏目】模块栏目列表({dirname}/) "article\/([0-9]+)\/([0-9]+)\.html" => "index.php?c=show&id=$1&page=$2", //【共享栏目】模块内容页(分页)(article/{id}/{page}.html) "article\/([0-9]+)\.html" => "index.php?c=show&id=$1", //【共享栏目】模块内容页(article/{id}.html) // 共享栏目---解析规则----结束 // 共享模块---解析规则----开始 "so\/(.+)" => "index.php?s=$1&c=search&rewrite=$2", //【共享模块】模块搜索页(分页)({modname}/so/{param}/) "so" => "index.php?s=$1&c=search", //【共享模块】模块搜索页({modname}/so/) // 共享模块---解析规则----结束 // 独立模块---解析规则----开始 "([a-z]+)\.html" => "index.php?s=$1", //【独立模块】模块首页({modname}.html) "([a-z]+)\/list\/([0-9]+)\/([0-9]+)\.html" => "index.php?s=$1&c=category&id=$2&page=$3", //【独立模块】模块栏目列表(分页)({modname}/list/{id}/{page}.html) "([a-z]+)\/list\/([0-9]+)\.html" => "index.php?s=$1&c=category&id=$2", //【独立模块】模块栏目列表({modname}/list/{id}.html) "([a-z]+)\/show\/([0-9]+)\/([0-9]+)\.html" => "index.php?s=$1&c=show&id=$2&page=$3", //【独立模块】模块内容页(分页)({modname}/show/{id}/{page}.html) "([a-z]+)\/show\/([0-9]+)\.html" => "index.php?s=$1&c=show&id=$2", //【独立模块】模块内容页({modname}/show/{id}.html) "([a-z]+)\/search\/(.+)\.html" => "index.php?s=$1&c=search&rewrite=$2", //【独立模块】模块搜索页(分页)({modname}/search/{param}.html) "([a-z]+)\/search\.html" => "index.php?s=$1&c=search", //【独立模块】模块搜索页({modname}/search.html) // 独立模块---解析规则----结束 ];
上面是rewrite.php 文件配置
改成唯一模式