Zend Framework on shared hosting

后端 未结 12 1446
孤独总比滥情好
孤独总比滥情好 2020-12-04 17:01

I\'m new to Zend Framework. I would like to know how to implement zend framework on a shared hosting. Because of the zend framework folder structure all view files are put i

12条回答
  •  [愿得一人]
    2020-12-04 17:39

    i think the best way is to remove the .htaccess from the public directory (Zend Framework Directory structure) , and put it with the following content into your "root" directory :

     
    RewriteEngine On

    RewriteRule ^.htaccess$ - [F] RewriteCond %{REQUEST_URI} ="" RewriteRule ^.*$ /public/index.php [NC,L]

    RewriteCond %{REQUEST_URI} !^/public/.$ RewriteRule ^(.)$ /public/$1 RewriteCond %{REQUEST_FILENAME} -f RewriteRule ^.*$ - [NC,L]

    RewriteRule ^public/.*$ /public/index.php [NC,L]

提交回复
热议问题