Welcome Guest, Not a member yet? Register   Sign In
Running CI on Amazon Servers - Trouble with htaccess
#1

[eluser]Xeoncross[/eluser]
Ok, I can't believe that I am having trouble with this - but I can't get htaccess to work on amazons servers!

I have tried all of these and I can't access the page without the "index.php" file in the URL!
Code:
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteBase /dev4/
  #RewriteBase /
  RewriteCond %{REQUEST_FILENAME} !-f
  RewriteCond %{REQUEST_FILENAME} !-d
  RewriteRule ^(.*)$ /index.php/$1 [L]
</IfModule>

Code:
# Deny OR Allow Folder Indexes.
# Since we disable access to PHP files you
# can leave this on without worries.
# OR better yet, create a .htaccess file in
# the dir you want to allow browsing and
# set it to +Indexes
Options -Indexes

Options +FollowSymLinks

# Set the default file for indexes
DirectoryIndex index.php

<IfModule mod_rewrite.c>
    # mod_rewrite rules
    RewriteEngine on
    
    # The RewriteBase of the system (if you are using this sytem in a sub-folder).
    #RewriteBase /
    #RewriteBase /dev4
    
    # If the file is NOT the index.php file
    RewriteCond %{REQUEST_FILENAME} !index.php
    # Hide all PHP files so none can be accessed by HTTP
    RewriteRule (.*)\.php$ index.php/$1
    
    # If the file/dir is NOT real go to index
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [QSA,L]
    
</IfModule>

# If Mod_ewrite is NOT installed go to index.php
<IfModule !mod_rewrite.c>
    ErrorDocument 404 index.php
</IfModule>

The address is something like http://sub.site.com/dev4/
Has anyone ever used the Amazon servers before and knows some trick I don't?


accessing http://sub.site.com/dev4/welcome/ gives me an apache not found error, and accessing http://sub.site.com/dev4/index.php/welcome/ gives me a CI 404 error.

I have removed the $config['index_page'] = ""; as well.


Messages In This Thread
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-07-2008, 07:10 PM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-07-2008, 08:29 PM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-07-2008, 09:26 PM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-08-2008, 12:06 PM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-08-2008, 02:49 PM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 11-09-2008, 09:08 AM
Running CI on Amazon Servers - Trouble with htaccess - by El Forum - 07-19-2009, 10:36 AM



Theme © iAndrew 2016 - Forum software by © MyBB