Click or drag to resize
ISKUUrlServiceGetSKUUrl Method
Returns absolute live site URL of a product. If sku represents product variant, returns URL to the main product.

Namespace: CMS.Ecommerce
Assembly: CMS.Ecommerce (in CMS.Ecommerce.dll) Version: 13.0.131
Syntax
C#
string GetSKUUrl(
	SKUInfo sku,
	string cultureCode
)

Parameters

sku
Type: CMS.EcommerceSKUInfo
SKU
cultureCode
Type: SystemString
Culture code.

Return Value

Type: String
Exceptions
ExceptionCondition
ArgumentNullExceptionWhen sku or cultureCode is null.
ArgumentExceptionWhen sku is global or standalone, when the product is not persisted in database, when product site is incorrect, or when the specified cultureCode is not allowed on site.
Remarks
Does not support global or standalone SKUs. When sku page is not translated to the specified cultureCode, returns product URL in different culture, where the translation exists (site default culture is prioritized).
See Also