Skip to main content
Products with many configuration options, such as printed matter, produce long addresses because every selected option is appended as a parameter. Such an address cannot be passed on or written down:
The link shortener instead offers the customer a short link that leads back to exactly this configuration when called up:
Short link 1 The practical benefit lies with the customer: they save the short link, call it up again later and find their product with all the settings they made, without having to put them together again.
The link shortener is a standalone function and technically has nothing to do with SEO URLs. The two can be used independently of each other.
Guide: SEO URLs and link optimization

Requirements

The function works with AJAX and a layer above the page. It is therefore only available to customers who have JavaScript enabled in their browser.
Reloading via AJAX counts as a page view and therefore increases the number of performance units. For a product that many customers configure, this is not a side effect but a figure that belongs in your cost calculation.
The function must be activated and configured by WEBSALE. Tell your contact person for which subshops you want it.

Setting up

Step 1: Add the call to the product detail view

Short link direct link generated The product detail view ws_product.htm contains the link the customer uses to request the short link. In the example, the link is created for the product including the selected variants.
Which link is shortened is determined by the parameter of WS-PrepareForShortURL(). In the example, this is PR-DepVarLink, that is, the product link with the selected variants. For a different short link, insert a different link tag there. Reference: WS-PrepareForShortURL

Step 2: Include the JavaScript library

The WEBSALE system library and the design component must be included on the product detail view, at least in version 1.8.1.
Materials: WEBSALE JavaScript library Guide: JavaScript and jQuery

Step 3: Create the template for the display

The click loads an additional template via AJAX that shows the customer the generated short link. Create it under the name used in the call from step 1 and save it in your template directory. Short link direct link
The name of the AJAX section must match the ID of the div from step 1, here ws_shortlink. Otherwise, the browser does not know which part of the page to replace.
The negative section is not optional. If no short link can be generated, the customer would otherwise see an empty layer and not know whether anything has happened.
Reference: WS-ShortURL
  • Guide: SEO URLs and link optimization
  • Guide: JavaScript and jQuery
  • Guide: AJAX functions