Welcome Guest, Not a member yet? Register   Sign In
redirect a PHP suffix to a controller using Apache mod_rewrite / RewriteRule
#7

[eluser]tmcallister[/eluser]
[quote author="bretticus" date="1253740230"]Instead of using redirect, why not just configure CI to use the php extension? See Adding a URL Suffix

If that will not work for you, you might get better mileage with CI's URI Routing.

If you prefer a mod_rewrite rule, you might try this (untested.)
Code:
RewriteRule ^post_here.php$ index.php?/receive/index [L]
[/quote]

Thanks for taking the time to respond. Great points you make.

URL Suffix:
I am addressing a single integration point in a complex system. I don't want to force a URL suffix site wide to accommodate a single integration point.

Routing:
I started looking at routing 30 minutes ago. I don't find any documentation or examples that address the use of a php suffix, but I am still looking at it.

mod_rewrite
Unfortunately, I tried several variations of your suggested RewriteRule, each resulting in a 404 or no input file specified.


Thanks for your suggestions!


Messages In This Thread
redirect a PHP suffix to a controller using Apache mod_rewrite / RewriteRule - by El Forum - 09-23-2009, 10:32 AM



Theme © iAndrew 2016 - Forum software by © MyBB