阿里云Ubuntu系统+Apache2+PHP搭建gitblog

阿里云Ubuntu系统+Apache2+PHP搭建gitblog

Apache2以及PHP的安装这里就不介绍了,,网上一大堆。唯一需要总结的就是gitblog安装过程中的问题需要解决。

我遇到的问题是无法生成404 Not Found

需要apache支持rewrite, 改动有三处

修改内容apache2.conf, 在末尾加上

LoadModule rewrite_module /usr/lib/apache2/modules/mod_rewrite.so

修改 “AllowOverride None” 中的 “None” 为 “All”;

Options FollowSymLinksAllowOverride AllRequire all denied

在网站的根目录添加.htaccess,内容如下

RewriteEngine onRewriteCond %{REQUEST_FILENAME} !-fRewriteCond %{REQUEST_FILENAME} !-dRewriteCond $1 !^(index\.php|images|robots\.txt)RewriteRule ^(.*)$ /index.php/$1 [L]

版权声明:本文为博主原创文章,未经博主允许不得转载。

那里面非常漂亮,个个观景区都能看到奇形怪状的岩石。

阿里云Ubuntu系统+Apache2+PHP搭建gitblog

相关文章:

你感兴趣的文章:

标签云: