301 redirect for a url via web.config

I want to redirect a url to be be redirected to another url preserving querystring:

I want to redirect this url:

http://my.website.com/utilities/myservice.svc/item?longquerystring

to

http://my.website.com/utilities/myservice.svc/items?longquerystring

I have written the following code in my web.config:

<rewrite>
          <rules>
              <rule name="Test" patternSyntax="Wildcard" stopProcessing="true">
                  <match url="http://my.website.com/utilities/myservice.svc/item(.*)" />
                  <action type="Redirect" url="http://my.website.com/utilities/myservice.svc/items" 

appendQueryString="true" />
              </rule>
          </rules>
      </rewrite>

The above code is not working. Can you help me writing the correct rule there?

Answers


Need Your Help

Unable to open text file from WebBrowser control

javascript vb.net webbrowser-control text-files

I have a sample application, in which I am trying to load a text file in WebBrowser control. I have a html file through which I am calling Javascript function to open text file. But it is showing me

How to bind an NSTableView to multiple core data entity types

objective-c xcode cocoa core-data

I'm writing an application to help diabetics manage their condition. Information that is tracked includes blood sugar results, nutrition, exercise, and medication information.

About UNIX Resources Network

Original, collect and organize Developers related documents, information and materials, contains jQuery, Html, CSS, MySQL, .NET, ASP.NET, SQL, objective-c, iPhone, Ruby on Rails, C, SQL Server, Ruby, Arrays, Regex, ASP.NET MVC, WPF, XML, Ajax, DataBase, and so on.