Welcome Guest, Not a member yet? Register   Sign In
htaccess w/ subdomain
#1

[eluser]chandlerou[/eluser]
Having issues with htaccess with a subdomain.
I've tried other suggestions located on the forums, but none seems to work completely. I guess I might not be understanding the way htaccess works. Am I able to put one in any directory/subdomain I want? Will that override the htaccess located in my public_html?

Host:
Blue Host

References:
http://ellislab.com/forums/viewthread/98862/
http://codeigniter.com/wiki/Dreamhost_.htaccess/ (Solution 2)

Tested:
http://subdomain.domain.com/ - 404 Error
http://subdomain.domain.com/index.php - 404 Error
http://subdomain.domain.com/controller/ - Loading Correctly
http://subdomain.domain.com/index.php/controller - Loading Correctly


public_html/subdomain/.htaccess
Code:
<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

<IfModule !mod_rewrite.c>
    # If we don't have mod_rewrite installed, all 404's
    # can be sent to index.php, and everything works as normal.
    # Submitted by: ElliotHaughin

    ErrorDocument 404 /index.php
</IfModule>

public_html/subdomain/system/application/config/config.php (Changes Made)
Code:
$config['index_page'] = "";
And
Code:
$config['uri_protocol']    = "REQUEST_URI";
#2

[eluser]chandlerou[/eluser]
I am going to bed now...Found the problem

public_html/subdomain/system/application/config/routes.php
Code:
$route['default_controller'] = "controller_that_didnt_exist_FTW";

The wiki worked perfectly then. Thanks. ZZzzzzzzzzzz




Theme © iAndrew 2016 - Forum software by © MyBB