[CLUE-Tech] Regex Problem Using mod_rewrite

Jed S. Baer thag at frii.com
Fri Jul 23 16:03:08 MDT 2004


Hi Folks.

I'm sure there's some completely obvious thing here I'm overlooking, but
I'm flabbergasted by this.

I need to use mod_rewrite to redirect a few URLs. All I need to do is
change thing.htm to thing.php where thing=several different pages. So I
set up a mod_rewrite:

ReWriteRule ^/(foo|bar|pickle|thing|paddle|mumble)\.htm$ /$1.php
[R=permanent,L]

This works for foo,bar, thing, and mumble, but not for pickle or paddle.
In fact, it appears it does not work for any string beginning with the
letter 'p'. I haven't tested it with an exhaustive array of words
beginning with p, that's just what's suggested by the results I'm getting.
Setting ReWriteLogLevel to 9 has not produced anything suggestive -- in
fact, there are log messages showing the rewrite for all strings where it
works, and nothing for those where it doesn't, meaning, I take it, that
the regex isn't matching.

neither 'perldoc perlretut' nor 'perldoc perlre' has led to me to any
blinding insights.

TIA for any help here.
jed
-- 
http://s88369986.onlinehome.us/freedomsight/

... it is poor civic hygiene to install technologies that could someday
facilitate a police state. -- Bruce Schneier



More information about the clue-tech mailing list