Uploaded image for project: 'PUBLIC - Liferay Portal Enterprise Edition'
  1. PUBLIC - Liferay Portal Enterprise Edition
  2. LPE-1499

Multiple languages using the same URL causes poor SEO



      Currently the same URL is used to display a website in multiple languages and this is bad for search engine optimization (SEO). To address this issue, a new property has been added to portal(-ext).properties which will automatically add the locale to the URL.


      1. Set this to 0 if the locale is not automatically prepended to a URL. This
      2. means that each URL could potentially point to many different languages.
      3. For example, the URL http://localhost:8080/web/guest/home could then be
      4. viewed by users in many different languages.
      5. Set this to 1 if the locale is automatically prepended to a URL when the
      6. requested locale is not the default locale. This means that each URL
      7. points to just one language. For example, the URL
      8. http://localhost:8080/web/guest/home would point to the default language.
      9. The URL http://localhost:8080/zh/web/guest/home and
      10. http://localhost:8080/zh_CN/web/guest/home would both point to the Chinese
      11. language.
      12. In cases where the prepended locale is "zh" and not complete locale
      13. "zh_CN", then the full locale returned will be based on the order in which
      14. the locales appear in the property "locales". If "zh_CN" appears before
      15. "zh_TW", then "zh" will be a short hand for "zh_TW".
      16. The default language is set in system.properties with the properties
      17. "user.country" and "user.language".
      18. Set this to 2 if the locale is automatically prepended to every URL. This
      19. means that each URL points to just one language.
      20. Note that each language requires an entry in the property "locales" and a
      21. servlet mapping in web.xml for the I18n Servlet.


        Issue Links



              kristoffer.onias Kristoffer Onias
              brian.chan Brian Chan
              0 Vote for this issue
              0 Start watching this issue




                  Version Package
                  5.1 EE SP5 (5.1.8)
                  5.2 EE SP2 (5.2.6)