Codeigniter htaccess error using godaddy server go to 404 page

Discussion in 'PHP' started by praveenvijay, May 18, 2014.

  1. #1
    I have developed codeigniter based web application.its working perfectly on my localhost,remove index.php in url using htaccess.

    I am using godaddy server upload entire file to server and run it. it getting an error 404 error page. i am accessing every controller in url go to 404 error page.

    I am manaually include index.php in url it worked.

    ex www.mysite.com/demo/admin/login (not worked)

    www.mysite.com/demo/admin/index.php/login(worked fine)

    i have mention my htaccess code here

    RewriteEngine on
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*)$ index.php?/$1 [L,QSA]
    Anybody help me,thanks
     
    praveenvijay, May 18, 2014 IP
  2. stephan2307

    stephan2307 Well-Known Member

    Messages:
    1,277
    Likes Received:
    33
    Best Answers:
    7
    Trophy Points:
    150
    #2
    Solution: Don't use godaddy servers.
     
    stephan2307, May 27, 2014 IP
  3. sincos

    sincos Active Member

    Messages:
    64
    Likes Received:
    0
    Best Answers:
    1
    Trophy Points:
    51
    #3
    Lets try with this htaccess

    RewriteEngine on
    Options -Indexes
    RewriteCond $1 !^(player|images|js|css|favicon\.ico|index\.php|robots\.txt)
    RewriteRule ^(.*)$ index.php?/$1 [L]

    and try change the in the config file

    $config['uri_protocol'] = 'AUTO';//PATH_INFO or QUERY_STRING or REQUEST_URI or ORIG_PATH_INFO
     
    sincos, Jun 3, 2014 IP