Experience Optimization TCDL tag reference

This topic provides a list of the TCDL tags available for Experience Optimization.

TCDL tag libraries

Experience Optimization provides two sets of TCDL tags:

  • If you have an ASP.NET or JSP website and your published content is to be retrieved by website visitors, transform TCDL during publishing to create ASP.NET or JSP code on your published webpage at request time.
  • If you have a website that uses a different technology than ASP.NET or JSP (or if your published content is consumed by the Content Delivery web service), set your output format to REL to transform TCDL at request time.

Syntax

The following example shows all of the Experience Optimization tags you can use:

<tcdl:region>
  <tcdl:query>
    <tcdl:search /> (deprecated)
    <tcdl:attribute />
    <tcdl:promotions />
    <tcdl:items /> (deprecated)					
 </tcdl:query>
</tcdl:region>

Experience Optimization tags

Experience Optimization provides the following TCDL tags:

<tcdl:region>
The <tcdl:region> tag is the root node that encapsulates a Page Region in which Promotions returned by Elasticsearch are displayed.
<tcdl:query>
The <tcdl:query> defines a query for retrieving content that is displayed in a Page Region.
Use the following tags to influence what kind of query is sent to Elasticsearch:
<tcdl:search> (deprecated)
Defines a search Promotion that displays content items depending on search terms entered by the user. Search functionality within Experience Optimization is deprecated as of the SDL Tridion Sites 9 release.
<tcdl:attribute>
Defines a name and value pair that is added to the Elasticsearch query to allow you to filter Promotions, items returned by a Promotion, or items returned by a query on attributes.

Use the following tags to determine what to do with the results (the list of Promotions) that are returned by the query:

<tcdl:promotions>
Identifies a region for displaying Promotion items returned by a Elasticsearch query, including alternative content if Experience Optimization times out or no content is returned.
<tcdl:items> (deprecated)
Handles content items returned by a search query.