Welcome Guest, Not a member yet? Register   Sign In
mod_rewrite
#3

[eluser]timaksu[/eluser]
awesome. i replaced the indexpage area in config.php with :

Code:
if(in_array('mod_rewrite',apache_get_modules())) {
$config['index_page'] = "";
}
else
{
$config['index_page'] = "index.php";
}

and the .htaccess is
Code:
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteRule ^$ index.php [L]

RewriteCond $1 !^(index\.php|install\.php|style|js|robots\.txt|favicon\.ico)

RewriteRule ^(.*)$ index.php/$1 [L]
</IfModule>

the php checks to see if we have mod_rewrite enabled, and if we do we use index.php/ and it works fine with the rest of the site.

i was using base_url() for my anchors (Adding page names to the end as needed, eg; echo base_url()."welcome/etc"Wink

would i have any problems with this? compatibility etc?


Messages In This Thread
mod_rewrite - by El Forum - 05-13-2009, 09:53 AM
mod_rewrite - by El Forum - 05-13-2009, 09:57 AM
mod_rewrite - by El Forum - 05-13-2009, 07:53 PM
mod_rewrite - by El Forum - 05-14-2009, 01:56 AM
mod_rewrite - by El Forum - 06-01-2009, 06:47 PM
mod_rewrite - by El Forum - 06-02-2009, 04:38 AM



Theme © iAndrew 2016 - Forum software by © MyBB