views:

90

answers:

1

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" />

however 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" />
+1  A: 

should be like

<add name="category" virtualUrl="^~/Category.aspx/(.*)/(.*)" destinationUrl="~/Category.aspx?CatID=$1&amp;gclid=$2" ignoreCase="true" rewriteUrlParameter="ExcludeFromClientQueryString" />
Muhammad Akhtar