Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • Vrushank 11 posts 61 karma points
    Jun 01, 2015 @ 06:58
    Vrushank
    0

    Urlrewriting problem

    Hi,

    I have an issue with UrlRewriting.

    Below is my rule.

    <add name="301/xyz"  virtualUrl="/xyz" destinationUrl="/abc" redirectMode="Permanent"  redirect="Domain" ignoreCase="true" rewriteUrlParameter="IncludeQueryStringForRewrite"  />
    

    I want to redirect xyz page to abc page.That is working fine. But when /xyz/123 url comes then it is not working proper.

    Can anyone help me?

    And I'm using Umbraco 6.0.5.

    Regards, Vrushank

  • Urvish 252 posts 776 karma points
    Jun 01, 2015 @ 07:03
    Urvish
    100

    Hi Vrushank,

    You can put $ in end of the virtual url.

    It will consider exact url means that is end of url.

    Your code would be like below.

    <add 
     name="301/xyz"  
     virtualUrl="/xyz$" 
     destinationUrl="/abc" 
     redirectMode="Permanent"  
     redirect="Domain" 
     ignoreCase="true" 
     rewriteUrlParameter="IncludeQueryStringForRewrite" />
    

    Check below code. It is working or not.

    Hope this wil help.

    Regards,

    Urvish Mandaliya

  • Vrushank 11 posts 61 karma points
    Jun 01, 2015 @ 07:12
    Vrushank
    0

    Thank you Urvish Mandaliya for the reply.

    This is working like a charm. It makes my day.

    Thanks.

Please Sign in or register to post replies

Write your reply to:

Draft