Clean URL in a Multi Tenanted Environment using mod rewrite
Hi
I have successfully set up fop2 and have got it working in a multi tenanted environment but would like it to work with clean URLs
each on e of our contexts will be 4 alpha characters so I have this in my virtual host config
RewriteEngine On
RewriteRule ^([a-z]{4})$ /?context=$1
And have tried a lot of permutations of the above.
I know that mod rewrite is enables because if I put /abc at the end of the user I get an apache error whereas if I put /abcd I get a fop2 login but it's like it ignores the context aspect.
Does anyone have any ideas about this?
I have successfully set up fop2 and have got it working in a multi tenanted environment but would like it to work with clean URLs
each on e of our contexts will be 4 alpha characters so I have this in my virtual host config
RewriteEngine On
RewriteRule ^([a-z]{4})$ /?context=$1
And have tried a lot of permutations of the above.
I know that mod rewrite is enables because if I put /abc at the end of the user I get an apache error whereas if I put /abcd I get a fop2 login but it's like it ignores the context aspect.
Does anyone have any ideas about this?
Comments
http://www.latenightpc.com/blog/archive ... od_rewrite
Thanks for the tip, it really helped.
So, the working condition I've got to is:
RewriteRule ^/([a-z]{4})$ ?context=$1 [L,R]
The key bit here is the R flag which issues a redirect to the browser and we end up at the messy URL again, which has got me wondering; where exactly is the get variable being picked up? Is it being pulled by php or extracted from the URL string by the javascript?