WebSphere Commerce foundation tag library
The WebSphere Commerce foundation JSTL tag library is a collection of custom tags provided to you to support the authoring of WebSphere Commerce JSP files. WebSphere Commerce stores use the JavaServer Pages Standard Tag Library (JSTL) to perform logic, instead of Java code. At the same time, business logic is moved into data beans. The combination of these steps allows for less Java code in a JSP page.
The WebSphere Commerce foundation JSTL tag library, wcf, consists of the following tags:
- Tag: cdata
The wcf:cdata tag sets the specified data in XML format within a CDATA section and encodes the string that ends a CDATA section to avoid nested CDATA sections.- Tag: contextData
The wcf:contextData tag sets a business context data value for a WebSphere Commerce service request. The business context data values specified with the wcf:contextData tag are appended to any business context values associated with the current session. The new business context values are in effect only for the current WebSphere Commerce service request. The values do not persist into the session. Use this tag only as a tag of the wcf:getData tag.- Deprecated feature Deprecated feature: Tag: declareService
The wcf:declareService tag adds client-side support for invoking a service request. The ID is used to register the specified service so it can be invoked with the wc.service.invoke(serviceId, parameters) function. The parameters parameter is an object map that is passed as parameters to the service URL.- Deprecated feature Deprecated feature: Tag: declareRenderContext
The wcf:declareRenderContext tag adds the client-side render context support to the current page. The ID passed to this tag is used to identify the render context. If this tag is already called for this request and ID, then no further call is made.- Deprecated feature Deprecated feature: Tag: declareRefreshController
The wcf:declareRefreshController tag declares a refresh area controller. The refresh area controller provides the JavaScript logic that listens to changes in the render context and the model. It refreshes the refresh areas that are registered to the controller. Refresh areas are declared using the wc.widget.RefreshArea widget and by specifying the ID of a declared refresh controller for the controllerId attribute.- Tag: defineObjects
The wcf:defineObjects tag defines the renderContext and businessContext objects in a JSP page. The renderContext object maps render context name and values to single value render context string values. The businessContext object maps business context data names to the current value for the names.- Tag: eMarketingSpotCache
We can include the wcf:eMarketingSpotCache tag within an e-Marketing Spot JSP fragment to indicate that the JSP fragment is to be dynamically cached. This tag dynamically sets dependency IDs for e-Marketing Spot cache entries.- Tag: getData
The wcf:getData tag retrieves data objects from a WebSphere Commerce service. The wcf:param tag and the wcf:contextData tags are elements of the wcf:getData tag.- Tag: json
The wcf:json tag converts a specified Java object to JavaScript Object Notation (JSON).- Tag: metadata
The wcf:metadata tag retrieves metadata information that can be returned in response to a Get BOD request used for authoring. For example, workspaces in Management Center.- Tag: param
The wcf:param tag adds a named parameter value to the parent tag. The wcf:param tag can be specified as a element of the wcf:getData tag.- Tag: rest
The wcf:rest tag sends REST requests.- Tag: set
The wcf:set tag adds values into an object, such as Collections or Maps, that is created with the wcf:useBean tag.- Tag: out
The wcf:out tag is used to display the output to the user. This tag provides an option to use an encoding library to encode the output value, protecting against possible cross-site scripting attacks.- Tag: url
The wcf:url tag builds a URL and applies the appropriate WebSphere Commerce supported rewriting rules.- Tag: useBean
The wcf:useBean tag creates a list or map object.
Related concepts
Web enablement for the client library
Related reference
GetData tag configuration