Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Zend framework: "url not found" only with index controller, only if lowercase

This is my problem:

I have a working zend application running on aruba/linux. It seems to work well.

I have some controllers: index, user, video, ...

if i type "http://www.foo.com/public/" i can reach my index controller and index action. if i type "http://www.foo.com/public/user/register" i can reach my user controller and register action.

if i type "http://www.foo.com/public/index/index" the server return url not found :(

But the most strange thing is that if i type "http://www.foo.com/public/Index/index" (pay attention on the UPPERCASE I) it works.

I try an explanation, but i don't found it :(

Can you help me??

Thanks in advance, Gabriele.

PS: in locale on my computer it works well


UPDATE

a behavior that i didn't notice this afternoon: if i call a controller that doesn't exist zend show the custom error page with write that there isn't the specified controller. With the index controller i obtain instead 404: url not found...

i absolutely don't know what to do... please help me!!


RE-UPDATE

I've changed the default controller from 'index' to 'foo', i have renamed all files, classes and folder correctly and the application works well, without this stupid error...

It seems that the 'index' word creates some kind of bug.. It's a kind of magic...

like image 537
Gabriele Avatar asked Jan 17 '23 13:01

Gabriele


1 Answers

I had the same problem.

The problem was in my Virtual host setting. I had the following settings in my Directory of my Virtual host:

<Directory /home/koen/zend/ZendCMS/public>
            Options Indexes FollowSymLinks MultiViews ExecCGI
            AllowOverride All
            Order Deny,Allow
            Allow from all
</Directory>

When I put a dash in front of MultiViews and that fixed the problem.

Like this:

<Directory /home/koen/zend/ZendCMS/public>
            Options Indexes FollowSymLinks -MultiViews ExecCGI
            AllowOverride All
            Order Deny,Allow
            Allow from all
</Directory>

Hope that helps

like image 171
Koen Hendriks Avatar answered Apr 28 '23 03:04

Koen Hendriks