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. Web Design
    4. Long URLs due to foreign characters

    Long URLs due to foreign characters

    Web Design
    5 2 1.2k
    • 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.
    • RyanKent
      RyanKent last edited by

      I have a site which provides forum sections for various languages. When foreign characters are used in the post title, each letter is replace by a three character replacement such as %93. This conversion makes the URLs long.

      The site's software automatically uses the thread's title in the URL. It is never a problem except in these instances.

      Any suggestions on how to handle this issue?

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

        Hey Ryan-

        What software are you using?

        Depending on your coding experience, you may be able to set up replacements for the foreign characters and override the URL generating function.

        Just let me know, I may be able to help you out.

        -John

        RyanKent 1 Reply Last reply Reply Quote 0
        • RyanKent
          RyanKent @blu42media last edited by

          XenForo is the forum software in use.

          I was really wondering what type of replacement process would be used?

          When Google crawls a russian or korean site, do they convert the characters? If not, is there a way of telling Google "hey, this title is from the Russian forums so please use the Russian alphabet?"

          If they do still convert the characters, how do other countries handle this change? The title length would be reduced by two-thirds.

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

            You should have a meta tag for the page language (adjust language code as needed):

            As far as the URLs go... many sites are converting these to non-escaped variants on save.  Magento, for example, treats e, é, and ê as e in the url.  Check out Lemonde.fr, french news source.  They are just stripping the accents as well.

            To adjust for the accents, you would need to transliterate them.  First, find the function that is generating the URL.  Next, if your system allows has the iconv() function:

            $new_url = iconv('utf-8', 'us-ascii//IGNORE//TRANSLIT', $old_url);

            If not... then you could go this sort of route:

            $table = array(

            'Š'=>'S', 'š'=>'s', 'Đ'=>'Dj', 'đ'=>'dj', 'Ž'=>'Z',

            'ž'=>'z', 'Č'=>'C', 'č'=>'c', 'Ć'=>'C', 'ć'=>'c',

            'À'=>'A', 'Á'=>'A', 'Â'=>'A', 'Ã'=>'A', 'Ä'=>'Ae',

            'Å'=>'A', 'Æ'=>'A', 'Ç'=>'C', 'È'=>'E', 'É'=>'E',

            'Ê'=>'E', 'Ë'=>'E', 'Ì'=>'I', 'Í'=>'I', 'Î'=>'I',

            'Ï'=>'I', 'Ñ'=>'N', 'Ò'=>'O', 'Ó'=>'O', 'Ô'=>'O',

            'Õ'=>'O', 'Ö'=>'Oe', 'Ø'=>'O', 'Ù'=>'U', 'Ú'=>'U',

            'Û'=>'U', 'Ü'=>'Ue', 'Ý'=>'Y', 'Þ'=>'B', 'ß'=>'ss',

            'à'=>'a', 'á'=>'a', 'â'=>'a', 'ã'=>'a', 'ä'=>'ae',

            'å'=>'a', 'æ'=>'ae', 'ç'=>'c', 'è'=>'e', 'é'=>'e',

            'ê'=>'e', 'ë'=>'e', 'ì'=>'i', 'í'=>'i', 'î'=>'i',

            'ï'=>'i', 'ð'=>'o', 'ñ'=>'n', 'ò'=>'o', 'ó'=>'o',

            'ô'=>'o', 'õ'=>'o', 'ö'=>'oe', 'ø'=>'o', 'ù'=>'u',

            'ú'=>'u', 'û'=>'u', 'ü'=>'ue', 'ý'=>'y', 'ý'=>'y',

            'þ'=>'b', 'ÿ'=>'y', 'Ŕ'=>'R', 'ŕ'=>'r', 'Ā'=>'A',

            'ā'=>'a', 'Ē'=>'E', 'ē'=>'e', 'Ī'=>'I', 'ī'=>'i',

            'Ō'=>'O', 'ō'=>'o', 'Ū'=>'U', 'ū'=>'u', 'œ'=>'oe',

            'ß'=>'ss', 'ij'=>'ij'

            ); $new_url = strtr($old_url, $table);

            I'm not sure about Korean handling - perhaps someone else knows how these are being handled?

            -John

            RyanKent 1 Reply Last reply Reply Quote 1
            • RyanKent
              RyanKent @blu42media last edited by

              Thank you John.

              The solution you offered works if a site is geared for one particular language. The site I am working with has language dedicated forums covering more then a dozen languages. The end solution will need to adjust for all of them.

              I will speak to the forum software about your idea and hopefully we can build something off your suggestion. Thanks for taking the time to share your experience.

              1 Reply Last reply Reply Quote 0
              • 1 / 1
              • First post
                Last post
              • Does redirecting the existing URLs in the website without reducing our current rankings? The new website runs on the bubble, so it seems there is no provisions to redirect the existing URLs to this platform?
                0
                1
                51

              • Shortened URL is breaking when URL is in Upper Case
                sergeystefoglo
                sergeystefoglo
                0
                2
                265

              • URL Structure
                DonnaDuncan
                DonnaDuncan
                0
                3
                99

              • Interlinking using Dynamic URLs Versus Static URLs
                vivekrathore
                vivekrathore
                0
                5
                336

              • Is it ok to redirect an old URL to new URL with anchor tag?
                KristinaKledzik
                KristinaKledzik
                0
                6
                1.1k

              • URL Help
                KeriMorgret
                KeriMorgret
                0
                4
                77

              • Were our URLs setup correctly?
                KempRugeLawGroup
                KempRugeLawGroup
                1
                6
                121

              • Does Google count the domain name in its 115-character "ideal" URL length?
                MickEdwards
                MickEdwards
                1
                3
                2.8k

              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