Ok we have the following re-written URL using UrlRewriter.net
/category/games/21
using the following expression.
<rewrite url="~/Category/(.+)/(.+)" to="~/category.aspx?CatId=$2" />
how开发者_开发百科ever google can attach the following,
/category/games/21?gclid=clickIdHere
this would need to be re-written to,
/category.aspc?CatId=21&gclid=clickIdHere
Can anyone help suggest an expression that will work with the above?
I suppose somthing like...
<rewrite url="~/Category/(.+)/(.+)?gclid=(.+)" to="~/category.aspx?
CatId=$2&gclid=$3" />
should be like
<add name="category" virtualUrl="^~/Category.aspx/(.*)/(.*)" destinationUrl="~/Category.aspx?CatID=$1&gclid=$2" ignoreCase="true" rewriteUrlParameter="ExcludeFromClientQueryString" />
精彩评论