首页 > 程序开发 > Zend Framework的设置(apache)

Zend Framework的设置(apache)

2008年9月24日
  1. 编辑C:WINDOWSSystem32driversetchosts文件,增加一个域,如127.0.0.1  audit.local
  2. 修改的configure文件,在xampp环境下就是在d:/xampp//conf目录下,首先编辑httpd.conf,开启rewrite模块:将这行的注释去掉:LoadModule rewrite_module modules/mod_rewrite.so然后编辑extra/http-vhosts.conf文件,增加如下行:
    <VirtualHost *:80>
        DocumentRoot "D:/xampp/htdocs/"
        ServerName localhost
        ErrorLog logs/localhost.error_log
        CustomLog logs/localhost.access_log common
    </VirtualHost>
    <VirtualHost *:80>
        DocumentRoot "D:/xampp/audit/public/"
        ServerName audit.local
        ErrorLog logs/audit.error_log
        CustomLog logs/audit.access_log common
       
        RewriteEngine off
        <Location />
            RewriteEngine on
            RewriteCond %{REQUEST_FILENAME} !-f
            RewriteRule !.(js|ico|gif|jpg|jpeg|pdf|png|css)$ /index.
        </Location>
        <directory "D:/xampp/audit/public">
    #Allow server side include,cgi, disable directory index
          Options FollowSymLinks Includes ExecCGI
          Order allow,deny
          Allow from all
        </directory>
    </VirtualHost>
    然后去掉NameVirtualHost这行的注释,重新启动,就可以开始使用了更多关于apache rewrite rule的写法和说明。
    如果在nginx服务器上,参考nginx下的zend framework的设置
  3. 下载zend framework并安装到/lib目录下
  4. 建立项目的文件目录,你可以用最基本的zend framework quick start中推荐的结构,也可以直接使用我们项目使用的ZF1.6标准目录结构

此文发布时ZF的版本为1.6.1

相关文章:

  1. Nginx下zend framework的设置
  2. Zend Framework的项目目录结构
  3. Apache的directory配置
  4. 强制使用https的apache设置
  5. Apache URL rewrite

inetdemon 程序开发 , ,

  1. 本文目前尚无任何评论.
  1. 本文目前尚无任何 trackbacks 和 pingbacks.

Spam Protection by WP-SpamFree