Discussion: mod_rewrite madness
Afficher un message
Vieux 08/02/2007, 08h55   #4
HansH
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: mod_rewrite madness

"Michael Mol" <mikemol@gmail.com> schreef in bericht
news:eqe32g$vau$1@aioe.org...
> HansH wrote:
>>> However, I have been unable to come up with a RewriteRule that would
>>> replace occurances of + in the URL with %2B.

>> The rule is fed the unencoded URL where the + is replaced by a space

>
> So a rule like
>
> RewriteRule \ \%2B
> ought to work? I'll have to try that tomorrow.

You may have to quote the slash and space(s)

'Think you need to provide URLencode hrefs in your refering pages
AND url-escape the value of title in
RewriteRule ^wiki/?(.*)$ /.../index.php?title=$1 [L,QSA]
like
RewriteMap esc escape:
RewriteRule ^wiki/?(.*)$ /.../index.php?title=${esc:$1} [L,QSA,NE]

Note: RewriteMap not allowed in .htaccess ...

>> C# is your next stopper ...

> I've already given that thought. Intra-page links are a big part of my
> site's organization; I can't just replace the # symbol. I'll have to
> create an individual RewriteRule for C# and J#.

Hint: %23 in href

HansH


  Réponse avec citation
 
Page generated in 0,05953 seconds with 9 queries