views:

32

answers:

0

Let's say users browse to

http://www.site.com/test1/test2/test3

now I would like to rewrite the url to

http://www.site.com/index.cfm?var1=test1&var2=test2&var3=test3

So far I have added the following in the resin.conf file:

  <web-app id="/" root-directory="webroot">
    <rewrite-dispatch>
      <forward regexp="^/([^/]+)" target="?var1=$1"/>
    </rewrite-dispatch>
  </web-app>

This does change

http://www.site.com/test1

to

http://www.site.com/index.cfm?var1=test1

Now how should I change it so it adds all vars, it needs to be able to have less vars in the url aswell.