Question

I have the following bootstrap.php routing (its the default):

Route::set('default', '(<controller>(/<action>(/<id>)))')
    ->defaults(array(
        'controller' => 'Index',
        'action'     => 'index',
    ));

I have the following file structure:

application/
  classes/
    Constroller/
      Auth.php

I have the following .htaccess file:

# Turn on URL rewriting
RewriteEngine On

# Installation directory
RewriteBase /

# Protect hidden files from being viewed
<Files .*>
    Order Deny,Allow
    Deny From All
</Files>

# Protect application and system files from being viewed
RewriteRule ^(?:application|modules|system)\b.* index.php/$0 [L]

# Allow any files or directories that exist to be displayed directly
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d

# Rewrite all other URLs to index.php/URL
RewriteRule .* index.php/$0 [PT]

I am on an opensuse 11 Amazon EC2 instance and when I go to mydomain.com/auth or mydomain.com/Auth I am getting a generic 404 message from Apache. Is there something wrong in my htaccess possibly?

Was it helpful?

Solution

Make sure the htaccess file is readable by apache (e.g. 644 or some similar mode) and that the AllowOverride setting in the server/vhost config is set to something appropriate (All or FileInfo).

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top