联系官方销售客服
QQ1835022299
028-61286886
插件 | 多网站系统 V4.9 |
应用作者 | 太阳成游戏网站官方团队 |
发布时间 | 2019-07-08 08:10:35 |
更新时间 | 2025-06-11 09:27:34 |
多网站系统,如果创建了多个站点并且使用了自定义字段作为url,伪静态下
后台的URL规则使用自定义函数{zdyurl($data)},存放url对应的文章id,
比如
主站www.123.com的存放在
WRITEPATH . 'myid/' . md5(urldecode(CMSURI)) . '.txt';
次战en.123.com的存放在
WRITEPATH . 'myid_en/' . md5(urldecode(CMSURI)) . '.txt';
问题来,那共用的/config/rewrite.php里的
if (CMSURI)
{
$myfile = WRITEPATH . 'myid/' . md5(urldecode(CMSURI)) . '.txt';
if (is_file($myfile))
{
$id = file_get_contents($myfile);
if ($id)
{
return [
CMSURI => 'index.php?c=show&id=' . $id,
];
}
}
}
怎么判断哪个站走哪个txt呢?
插件教程:/doc/app-423.html