Document Properties
Kbid
27687M
Last Modified
19-Oct-2023
Added to KB
20-Jul-2016
Public Access
Everyone
Status
Online
Doc Type
Concepts
Product
ICM 7.10
Concept - Language-Specific and Region-Specific URLs

Table of Contents


Introduction

To avoid duplicate content web sites can make use of the canonical link. When pages for different languages/regions come into play there you can use the href lang link in the HTML <head> section to indicate similar content for other languages/regions (e.g., on product detail pages, content pages, catalog pages). These links can be enabled/disabled in the channel specific preferences.

References

Example

The United States product page under http://myshop.com/en/products/yellow_sweater (en-us) may have the same content as the British pendant (en-gb). It is a good practice to use the <link> element with a hreflang attribute set for all languages to avoid duplicate content. So search engines provide language/region specific results and content is not regarded as duplicated.

product page
<head>
  ..
  <link rel="alternate" hreflang="en-us" href="http://myshop.com/us/product/yellow_sweater" />
  <link rel="alternate" hreflang="en-gb" href="http://myshop.com/uk/product/yellow_sweater" />
  <link rel="alternate" hreflang="de-de" href="http://myshop.com/de/produkt/gelber_pullover" />
</head>

Target

Link elements with the hreflang attribute are placed in the <head> section of HTML storefront pages. They are automatically created in all available languages on the following pages: product pages, catalog pages, content pages and the Store Finder page.

Configuration

  1. Log on to the Commerce Management application.
  2. Go to Channel Preferences.
  3. Go to the SEO Settings section.
  4. Here you can enable/disable the href lang feature.

Approach

Use the Custom Link Rewriting to create links like:

Page
Custom Link
Product Detail

product://sku@domain?localeId=en_US

Category Detail

catalog://category-id@catalog-id?localeId=en_US

Content Page

page://page-id?localeId=en_US

Any page pipeline://ViewStorefinder-Start?localeId=en_US&highlight=true

The appended parameter localeId determines the locale of the created link.

Technical

There are four pipelets supporting the href lang link generation:

  • CreateProductHRefLangList
  • CreateCategoryHRefLangList
  • CreatePageHRefLangList
  • CreatePipelineHRefLangList

The created custom links can be rendered using the <islink link="#hreflang:link#> module. Currently they are used in ViewStandardCatalog-Browse/Refresh, ViewProduct-Start, ViewContent-Start and in ViewStoreFinder-Start/Search/Paging .

The link element are currently rendered within the app_sf_responsive_cm/staticfiles/cartridge/templates/default/modules/cms/DefaultPageStructure.isml in dependence of the channel preference HRefLangEnabled is true or false.

Disclaimer
The information provided in the Knowledge Base may not be applicable to all systems and situations. Intershop Communications will not be liable to any party for any direct or indirect damages resulting from the use of the Customer Support section of the Intershop Corporate Web site, including, without limitation, any lost profits, business interruption, loss of programs or other data on your information handling system.
The Intershop Knowledge Portal uses only technically necessary cookies. We do not track visitors or have visitors tracked by 3rd parties. Please find further information on privacy in the Intershop Privacy Policy and Legal Notice.
Home
Knowledge Base
Product Releases
Log on to continue
This Knowledge Base document is reserved for registered customers.
Log on with your Intershop Entra ID to continue.
Write an email to supportadmin@intershop.de if you experience login issues,
or if you want to register as customer.