Link to home
Start Free TrialLog in
Avatar of taz8020
taz8020Flag for United Kingdom of Great Britain and Northern Ireland

asked on

asp.net redirect old pages

Hi I have a large redirect page made up of eg
<add key="/acatalog/Crayons.html" value="/ProductSection/Crayons.aspx"/>
problem is that they had loads of queries they could have

eg  /acatalog/Crystal_Products.html?imz_s=pgten7msnkp6fl0ppp8p87c0a0

is they a way to match anything upto the "?" so inother words ingnore the query string and redirect it?

the redirect
  <rule name="Old Page Redirects" stopProcessing="true">
          <match url=".*"/>
          <conditions>
            <add input="{OldPages:{REQUEST_URI}}" pattern="(.+)"/>
          </conditions>
          <action type="Redirect" url="{C:1}" appendQueryString="false" redirectType="Permanent"/>
        </rule>
Avatar of bepsoccer1
bepsoccer1
Flag of United States of America image

change to
appendQueryString="True"
Avatar of taz8020

ASKER

hi tried that but think as its trying to match "/acatalog/Crystal_Products.html" if it has the query string it does not fire. It must be something in the pattern bit
ASKER CERTIFIED SOLUTION
Avatar of bepsoccer1
bepsoccer1
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial