Note that there are some explanatory texts on larger screens.

plurals
  1. POZend Framework controller load failure puzzle
    primarykey
    data
    text
    <p>I have a <code>.htaccess</code> file that looks like this:</p> <pre><code>SetEnv APPLICATION_ENV development RewriteEngine On RewriteCond %{REQUEST_FILENAME} -s [OR] RewriteCond %{REQUEST_FILENAME} -l [OR] RewriteCond %{REQUEST_FILENAME} -d RewriteRule ^.*$ - [NC,L] RewriteRule ^.*$ index.php [NC,L] </code></pre> <p>If I browse to my site I'm testing with, say <a href="http://www.example.com/" rel="nofollow noreferrer">http://www.example.com/</a>, the index page loads correctly.</p> <p>This is a Zend Framework application, and therefore it should route things out to my controllers, as it does correctly if I go to <a href="http://www.example.com/index/index" rel="nofollow noreferrer">http://www.example.com/index/index</a> or <a href="http://www.example.com/index" rel="nofollow noreferrer">http://www.example.com/index</a>, specifying the controller + action, and just the controller, respectively.</p> <p>It also works if I do something like <a href="http://www.example.com/index/test" rel="nofollow noreferrer">http://www.example.com/index/test</a>, where I've defined another action on the index controller called test.</p> <p>But if I make a <code>TestController.php</code> file, and attempt to go to <a href="http://example.com/test/" rel="nofollow noreferrer">http://example.com/test/</a>, Apache is returning:</p> <pre><code>&lt;!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"&gt; &lt;html&gt;&lt;head&gt; &lt;title&gt;404 Not Found&lt;/title&gt; &lt;/head&gt;&lt;body&gt; &lt;h1&gt;Not Found&lt;/h1&gt; &lt;p&gt;The requested URL /path/to/website/root/public/index.php was not found on this server.&lt;/p&gt; &lt;hr&gt; &lt;address&gt;Apache/2.2.8 (Ubuntu) DAV/2 SVN/1.4.6 PHP/5.2.4-2ubuntu5.10 with Suhosin-Patch Phusion_Passenger/2.0.3 mod_perl/2.0.3 Perl/v5.8.8 Server at www.example.com Port 80&lt;/address&gt; &lt;/body&gt;&lt;/html&gt; </code></pre> <p>Can anyone see what I've screwed up here?</p> <p>Billy3</p> <p>EDIT: The configuration for my site looks something like:</p> <pre><code>Alias /MySiteRoot/ "/usr/local/vsites/something/www/" &lt;Directory /usr/local/vsites/something/www/&gt; Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all &lt;/Directory&gt; </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload