urlrewritefilter icon indicating copy to clipboard operation
urlrewritefilter copied to clipboard

outbound-rule example is wrong (2 errors) and incomplete description

Open GoogleCodeExporter opened this issue 10 years ago • 0 comments

Ref: http://tuckey.org/urlrewrite/manual/4.0/#outbound-rule

1) Missing in description (useful):
For enable parse of "path?querystring" you MUST add use-query-string="true" in 
urlrewrite tag

<urlrewrite use-query-string="true">


2) Regex example is wrong
    ^/world.jsp?country=([a-z]+)&amp;city=([a-z]+)$

? is a special character, right regex is:
    ^/world.jsp\?country=([a-z]+)&amp;city=([a-z]+)$


3) JSTL example is wrong
    <a href="<c:url value="/world.jsp?country=${country}&amp;city=${city}" />">nyc</a>

&amp; in querystring is not standard and cause regex fail, right JSTL is:
    <a href="<c:url value="/world.jsp?country=${country}&city=${city}" />">nyc</a>

Original issue reported on code.google.com by [email protected] on 28 Mar 2013 at 3:48

GoogleCodeExporter avatar Jul 05 '15 22:07 GoogleCodeExporter