Hello,
I am using following directory structure for zend framework development on my local machine and it is working fine. I am using WAMP for php development.
following is the directory structure.
siteroot
|- admin
|-application
|-controllers
|-models
|-view
|-public
|-css
|-images
|-js
|-index.php
|-application
|-controllers
|-models
|-view
|-library
|-Zend
|-public
|-css
|-images
|-js
|-index.php
For above structure if I write, http://localhost/siteroot/index/id/1, it opens site perfectly on local machine. but on server when I write http://glomera.kintudesigns.com/index/index/id/1, it gives message "No input file specified." That means it is not getting index.php. Why is it so?
I have also set .htaccess file on sever as below.
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php [L]
Same problem occurs for admin section http://glomera.kintudesigns.com/admin/index/id/1
Can anyone help me to solve this problem?
Thanks.
Re: Help needed in setting Zend Framework on server
Amar,
It seems that PHP is not configured properly on the server.
The very simple question: if you remove all .htaccess content, does the simple file with
<?php phpinfo();
show any output?
What is your server's configuration?
Regards,
Alex
Hello Alex, Following is the
Hello Alex,
Following is the link for phpinfo.php on my server.
http://glomera.kintudesigns.com/phpinfo.php
please refer it and let me know if you can figure out something..
Thanks.
Amar.
Re: Help needed in setting Zend Framework on server
I do not know exactly what cause the problem, but it seems that you need to change the mod_rewrite configuration. Try different RewriteCond/RewriteRule combinations, as described here:
http://framework.zend.com/manual/en/zend.controller.router.html
For example, the some examples seem similar to what you use, but have minor differences. So try to replace your with the following:
RewriteEngine on
RewriteCond %{SCRIPT_FILENAME} !-f
RewriteCond %{SCRIPT_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1
or
RewriteEngine on
RewriteRule !\.(js|ico|gif|jpg|png|css)$ index.php