站长资讯网
最全最丰富的资讯网站

sae index.php隐藏的设置方法

sae index.php隐藏的设置方法:首先在项目的根目录下找到“config.yaml”文件;然后添加代码为“rewrite: if(!is_dir() && !is_file() && path~”即可隐藏“index.php”。

sae index.php隐藏的设置方法

推荐:《PHP视频教程》

thinkphp5在SAE上部署隐藏index.php

我们可以使用SAE提供的AppConfig服务实现伪静态。在你项目的根目录下找到config.yaml文件(没有的话自己建一个),加上如下代码:

handle: - rewrite: if(!is_dir() && !is_file() && path~"^(.*)$") goto "index.php/$1"

这样就可以隐藏入口index.php。

赞(0)
分享到: 更多 (0)