安装教程参考:http://www.laozuo.org/8303.html
1.安装php扩展(比如安装mbstring)
先搜索相关的包
apt-cache search php7
再安装
apt-get install php7.0-mbstring
2.开启apache重写
先开启重写功能
sudo a2enmod rewrite
再修改/etc/apache2/sites-enabled/下对应的配置文件
<Directory /> Options FollowSymLinks
# 追加这行 AllowOverride All </Directory> <Directory "/var/www"> Options Indexes FollowSymLinks ExecCGI Includes AllowOverride All Order allow,deny Allow from all </Directory>