The Moz Q&A Forum

    • Forum
    • Questions
    • My Q&A
    • Users
    • Ask the Community

    Welcome to the Q&A Forum

    Browse the forum for helpful insights and fresh discussions about all things SEO.

    1. SEO and Digital Marketing Q&A Forum
    2. Categories
    3. Technical SEO Issues
    4. Lowercase Rewrite in web.config. Strange behavior.

    Lowercase Rewrite in web.config. Strange behavior.

    Technical SEO Issues
    4 3 892
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as question
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • Banknotes
      Banknotes last edited by

      So I am trying to implement a lower case rule in my rewrite section and I am using the same snippet below that can be found all over the web.

      The lower casing of my url works fine but it adds my domain name into the URL for reasons I can't explain.  so this  www.SomeSite.com/Upper.aspx become www.somesite.com/somesite/upper.aspx

      I removed all other rewrite rules but this one and still it happens.  Has anyone seen this?

      My server is IIS 7

      <match url="[A-Z]" ignorecase="false"></match>

      <action type="Redirect" url="{ToLower:{URL}}"></action>

      1 Reply Last reply Reply Quote 0
      • James_T
        James_T last edited by

        Hi Greg,

        You may need to be more specific in your query, e.g.

        <match url=".[A-Z]." ignoreCase="false" />

        Instead of:

        <match url="[A-Z]" ignorecase="false"></match>

        1 Reply Last reply Reply Quote 0
        • Banknotes
          Banknotes last edited by

          Hi James,

          I am not sure why but it seems that my problem was cache related... I went to work and saw that my urls were rewriting just fine.   Sorry I didn't get back to this thread for so long.

          Regards,

          Greg

          1 Reply Last reply Reply Quote 1
          • Aleyda
            Aleyda last edited by

            Hi Greg, great to hear that it's working ok and was a cache issue. Thanks for the update!

            1 Reply Last reply Reply Quote 0
            • 1 / 1
            • First post
              Last post
            • Strange Behavior - Dupe Content Via Query String URLs?
              Alder
              Alder
              0
              7
              85

            • Strange Crawl Report
              Neon_Rain
              Neon_Rain
              0
              3
              105

            • Redirecting special characters in .htaccess and web.config
              stephenfishman
              stephenfishman
              0
              7
              10.6k

            • How to Delete a Page on the Web?
              SebastianCowie
              SebastianCowie
              0
              2
              149

            • Web config redirects not working where a trailing slash is involved
              AndrewAkesson
              AndrewAkesson
              0
              5
              6.4k

            • Strange rank behavior
              SimonCullum
              SimonCullum
              1
              6
              810

            • Sharepoint SEO - How to lowercase urls with rewrite rules?
              aschottmuller
              aschottmuller
              0
              6
              2.9k

            • URL Rewrite
              Gaveltek-173238
              Gaveltek-173238
              0
              13
              1.9k

            Get started with Moz Pro!

            Unlock the power of advanced SEO tools and data-driven insights.

            Start my free trial
            Products
            • Moz Pro
            • Moz Local
            • Moz API
            • Moz Data
            • STAT
            • Product Updates
            Moz Solutions
            • SMB Solutions
            • Agency Solutions
            • Enterprise Solutions
            • Digital Marketers
            Free SEO Tools
            • Domain Authority Checker
            • Link Explorer
            • Keyword Explorer
            • Competitive Research
            • Brand Authority Checker
            • Local Citation Checker
            • MozBar Extension
            • MozCast
            Resources
            • Blog
            • SEO Learning Center
            • Help Hub
            • Beginner's Guide to SEO
            • How-to Guides
            • Moz Academy
            • API Docs
            About Moz
            • About
            • Team
            • Careers
            • Contact
            Why Moz
            • Case Studies
            • Testimonials
            Get Involved
            • Become an Affiliate
            • MozCon
            • Webinars
            • Practical Marketer Series
            • MozPod
            Connect with us

            Contact the Help team

            Join our newsletter
            Moz logo
            © 2021 - 2026 SEOMoz, Inc., a Ziff Davis company. All rights reserved. Moz is a registered trademark of SEOMoz, Inc.
            • Accessibility
            • Terms of Use
            • Privacy