We are excited to announce that the IIS.NET Forums are moving to the new Microsoft Q&A experience. Learn more >

How to rewrite URL in windows server 2016 IISRSS

2 replies

Last post Sep 10, 2020 09:24 AM by Jalpa Panchal

  • How to rewrite URL in windows server 2016 IIS

    Sep 04, 2020 08:51 PM|a.rahuman|LINK

    need to rewrite the URL

    FROM

    "name.ourdomain.com.kw:portnumber/apex/app?number&456service_number=123"

    TO

    "name.ourdomain.com.kw/anything"

  • Re: How to rewrite URL in windows server 2016 IIS

    Sep 07, 2020 05:39 AM|Jalpa Panchal|LINK

    Hi,

    You could try below URL rewrite rule:

     <rule name="rule1" stopProcessing="true">
                        <match url="(.*)" />
                        <conditions>
                            <add input="{HTTP_HOST}" pattern="^name.ourdomain.com.kw:portnumber$" />
                            <add input="{REQUEST_URI}" pattern="^/apex/app" />
                            <add input="{QUERY_STRING}" pattern="number&amp;(.*)service_number=(.*)" />
                        </conditions>
                        <action type="Redirect" url="http://name.ourdomain.com.kw/anything" appendQueryString="false" />
                    </rule>

    .NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today.
  • Re: How to rewrite URL in windows server 2016 IIS

    Sep 10, 2020 09:24 AM|Jalpa Panchal|LINK

    Hi,

    Is your issue solved?

    If your issue is solved then I request you to mark the helpful suggestion as an answer. This will help other people who face the same issue.

    If your issue still exists then try to refer the solution given by the community members.

    If then also you have any further questions then let us know about it.

    We will try to provide further suggestions to solve the issue.

    Thanks for your understanding.

    Regards

    Jalpa.

    .NET forums are moving to a new home on Microsoft Q&A, we encourage you to go to Microsoft Q&A for .NET for posting new questions and get involved today.