ISML Function - url()

Name

url()

Short Description

generate a URL that is part of a link dynamically (HTTP)

Table of Contents

Product Version

6.5

Product To Version

 

Statusfinal

1 Introduction

Webpages usually have links allowing a user to navigate from one page to another. A link in a standard webpage includes a URL pointing to another webpage.
If the user clicks on a link, the browser sends a request containing the URL to a server. In an Intershop 7 site, however, links do not reference other webpages. Instead, Intershop 7 links trigger pipelines which again can generate storefront webpages as a response.

The functions url() and urlex() are used in a template to dynamically generate a URL that is part of a link. Any reference in a storefront page needs to be generated by one of these function calls. Use the attribute action for generating that part of a URL that contains information about the storefront name, language/locale, currency, etc. The parameter attribute can be used to extend the URL with additional key-value pairs which can forward additional data to the called pipeline.

The url() function uses the protocol that triggered the pipeline. Therefore, if the pipeline was triggered via an HTTP request, the URL will use the HTTP protocol. If the pipeline was triggered via HTTPS, then that protocol will be used. By contrast, the urlex() function allows you to arbitrarily specify a protocol, independently of the one used in the current pipeline request.

2 Syntax

url( <action - operation> )
url( <action - operation>,[<parameter - operation>] )

3 Example

This example shows how to build a link in a storefront page to call a pipeline.

<a href = "#url(action('ViewBasketHistory-Start'))#">
  ... link text to be displayed ...
</a>

4 Parameters

4.1 action

This parameter is required.
action - operation
Result of an action() function call.

4.2 parameter

This parameter is optional.
parameter - operation
Result of a parameter() function call. The parameter() function may be included as often as needed in this function call.

Reference - ISML Functions

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.

Customer Support
Knowledge Base
Product Resources
Tickets