1

I am also having the same problem and I have tried almost every code available online for .htaccess

My Xamp is running on Linux, FYI - The application is on intranet not on internet, may be that cause some problem.

I have checked that mod_rewrite is enabled. it is showing under loaded modules when I run php.info() function.

In my config file

$config['base_url'] = ''; 
$config['index_page'] = '';
$config['uri_protocol' = 'AUTO';

my working url is arteri is a subdirectory in root http://whintranet.wh.tvh.ca/arteri/index.php/artery/home but when I removes index.php from it

The requested URL /arteri/artery/home was not found on this server. Apache/2.2.15 (CentOS) Server at whintranet.wh.tvh.ca Port 80

my.htaccess

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /arteri/

RewriteCond %{REQUEST_URI} ^system.*
RewriteRule ^(.*)$ /index.php?/$1 [L]

RewriteCond %{REQUEST_URI} ^application.*
RewriteRule ^(.*)$ /index.php?/$1 [L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L]
</IfModule>

any help greately appreciated

falsarella
  • 12,217
  • 9
  • 69
  • 115
Rajkaran07
  • 63
  • 1
  • 7
  • There's a missing closing bracket in the snippet from your config file `['uri_protocol']` ... also, you may need to add `QSA` to your last `RewriteRule`: `RewriteRule ^(.*)$ index.php?/$1 [QSA,L]` – keithhatfield Aug 02 '13 at 19:20

1 Answers1

0

Set your base url to the absolute path including protocol as stated in this answer. Don't forget the trailing slash

$config['base_url'] = 'http://whintranet.wh.tvh.ca/arteri/'; 
$config['index_page'] = '';
$config['uri_protocol' = 'AUTO';

Set your htaccess according to this answer

RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /arteri/index.php?/$1 [L]
Community
  • 1
  • 1