[FX.php List] [Off] Help with .htaccess RewriteRule or Redirect
Roger Moffat
rogerkiwi at aol.com
Fri Mar 21 16:21:31 MDT 2008
On Mar 21, 2008, at 6:03 PM, Troy Meyers wrote:
> I had presumed that I did not have access to httpd.conf. Speakeasy
> only said that I could use .htaccess file and that others use it for
> similar purposes. I presume that this means they have
> certain .htaccess features enabled by default, or that I could ask
> them to enable them. Perhaps Chris knows the answer since he deals
> with Speakeasy.
Wouldn't this be very similar to what is in the .htaccess file that
controls how BlackBelt runs?
I can't help with the syntax as I'm hopeless at regular expressions,
but I have this line in one of my Virtual Hosts listings
RewriteEngine On
RewriteRule /Genealogy/.* http://genealogy.clanmoffat.org/ [R]
and it works to take any request that included
/Genealogy/anthingAfterTheSlash
and redirect it to
http://genealogy.clanmoffat.org/
I see no reason why the same two lines in a .htaccess file wouldn't
work - just figure out what it is you need to say on each side of the
[space] there in that RewriteRule
but it seems like you're looking for something like
RewriteRule .*/flasking/.* http://lab.troymeyers.com/flasking/whatever
As I say I know nothing about the syntax of how to parse out what you
want (and to stop the rewrite if they've already arrived at
lab.troymeyers.com/flasking/whatever but from what I've learned in
other places I use Apache you should be able to accomplish what you
want in a .htaccess file with the correct regular expression.
Roger
More information about the FX.php_List
mailing list