The Preview tag library contains a single tag, <preview:repositoryItem>. The <preview:repositoryItem> tag inserts item identifiers in JSP pages. The tag library source and definition files are included in your ATG installation at the following location:
<ATG10dir>/WebUI/Preview/taglibs/webui-preview/lib
Copy the library to your site’s WAR file. For example, in Commerce Reference Store, the meta-inf/taglib.tld file can be found in <ATG10>/CommerceReferenceStore/Store/Storefront/j2ee-apps/Storefront/store.war/WEB-INF/lib/webui-preview-1_0.jar.
In order to call the <preview:repositoryItem> tag, the JSP must include this taglib directive:
<%@ taglib prefix="preview" uri="http://www.atg.com/taglibs/webui-preview_rt" %>
preview:repositoryItem
The <repositoryItem tag sets an explicit item identifier to be used in the body of a page. The identifier is calculated based on repository item data. The tag is defined as follows:
<preview:repositoryItem[item][repositoryName][itemType][itemID]>... </preview:repositoryItem>
Attribute | Description |
|---|---|
| Page parameter. (See the |
| Name of the repository that contains the asset |
| Asset type |
| Asset ID |
The following example is adapted from the Commerce Reference Store store.war/browse/gadgets/categoryPanel.jsp page, which renders links to the child categories pages for a specified category. In this example, the <preview:repositoryItem> tag calculates a class for the child category repository item generated by the CatalogItemLink servlet bean.
<preview:repositoryItem item="${childCategory}">
<dsp:droplet name="CatalogItemLink">
<dsp:param name="item" param="childCategory"/>
<dsp:oparam name="output">
<dsp:getvalueof id="url" idtype="String" param="url"/>
<li onmouseover="this.className='selected';"onmouseout="this.className='';">
<dsp:a page="${url}">
<dsp:valueof param="childCategory.displayName"/>
</dsp:a>
</li>
</dsp:oparam>
</dsp:droplet>
</preview:repositoryItem>For a list of all Commerce Reference Store JSP pages that are tagged with <preview:repositoryItem, see Tags for Visual Merchandising in the ATG Commerce Reference Store Overview.

