# 环境支持
[![](http://static.phpgrace.com/statics/images/video2.png)](https://ke.qq.com/course/310478)
**phpGrace 对 php 环境要求如下 :**
~~~
apache/nginx + php 5.3 + ( 使用命名空间 )
apache/nginx + php 7.0 +
~~~
**是的我们“嫌弃”且不支持 IIS + PHP ! ^\_^**
**php 扩展要求**
~~~
1、pdo
2、mbstring
3、gd
4、curl
5、其他扩展见对应工具类的使用说明
~~~
**伪静态支持说明**
phpGrace 需要 web 服务器的伪静态支持,请开启对应 web 服务器的伪静态模块!
**apache 服务器伪静态设置说明 :**
~~~
将 .htaccess 文件添加到对应分组模块文件夹下
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ ./index.php?pathInfo=$1 [QSA,PT,L]
~~~
**nginx 服务器伪静态设置示例 :**
~~~
server {
listen 80;
server_name www.phpgrace.com phpgrace.com;
root "D:/webs/www.phpgrace.com";
location /admin {
index index.html index.htm index.php;
if (!-e $request_filename){
rewrite ^/admin/(.*)$ /admin/index.php?pathInfo=$1;
}
}
location / {
index index.html index.htm index.php;
if (!-e $request_filename){
rewrite ^(.*)$ ./index.php?pathInfo=$1;
// 有些nginx 需要去掉 . 根据情况自己调整一下 (:
// rewrite ^(.*)$ /index.php?pathInfo=$1;
}
}
}
~~~
说明 :
/admin 代表 admin 分组(一般我们会将网站后端放置到此分组,命名可以自行设置);