Welcome Guest, Not a member yet? Register   Sign In
Fully qualified SEO URLs, how to be allowed to use them?
#19

[eluser]mteejay[/eluser]
[quote author="Joshua Logsdon" date="1250163628"]So far, so good with overriding the Router library's _set_request() method to change dashes found in the first two segments to underscores.

Attached is the MY_Router.php file (inside the .zip) that I'm using in my application/libraries/ directory and here is the addition to the method mentioned above:

Code:
for ( $i = 0; $i < 2; $i++ )
{
    if ( isset($segments[ $i ]) && strpos($segments[ $i ], '-') !== FALSE )
    {
        $segments[ $i ] = str_replace('-', '_', $segments[ $i ]);
    }
}
[/quote]

Is this solution still working with the latest release of CI (2.0.2)?


Messages In This Thread
Fully qualified SEO URLs, how to be allowed to use them? - by El Forum - 04-27-2011, 06:24 PM



Theme © iAndrew 2016 - Forum software by © MyBB