dsp:page encloses a JSP: the first tag follows the page directive and the last tag ends the page. dsp:page invokes the JSP handler, which calls the servlet pipeline and generates HTTPServletRequest. The servlet pipeline manages generic page-related tasks, such as retrieving the servlet session components, instructing the page to render its contents, and clearing cached information.

Attributes

Outputformat:xml

The xml attribute specifies the page output as HTML (false) or XML (true). Omitting this attribute uses xml="false"in all cases but one: if a parent page sets this attribute to true and a child page omits it, the true setting is applied to the child page. To designate different output types for parts of a page, use the tag dsp:setxml. See dsp:setxml for information.

Delimiter:useXmlParamDelimiter

The useXmlParamDelimiter attribute specifies the delimiter that is used by DynamoHTTPServletRequest.addQueryParam to separate query parameters. The options are as follows:

  • true indicates the XML delimiter &

  • false indicates the HTML delimiter &

A value provided by a dsp:page or dsp:setxml tag to a parent page is automatically inherited by an embedded page, unless the embedded page itself declares a delimiter. When no value is detected, the ATG platform uses the delimiter associated with the page’s MIME type.

Example

<%@ taglib uri=http://www.atg.com/taglibs/daf/dspjspTaglib1_0 prefix="dsp" %>
<%@ taglib uri='http://java.sun.com/jsp/jstl/core' prefix='c' %>

<dsp:page>

<dsp:droplet name="/atg/dynamo/droplet/Switch">
  <dsp:param bean="/atg/dynamo/servlet/RequestLocale.locale.language"
name="value"/>
  <dsp:oparam name="fr"><%response.sendRedirect("fr");%></dsp:oparam>
  <dsp:oparam name="de"><%response.sendRedirect("de");%></dsp:oparam>
  <dsp:oparam name="ja"><%response.sendRedirect("ja");%></dsp:oparam>
  <dsp:oparam name="en"><%response.sendRedirect("en");%></dsp:oparam>
  <dsp:oparam name="default"><%response.sendRedirect("en/default.jsp");%>
  </dsp:oparam>
</dsp:droplet>

</dsp:page>

This page points a user to pages written in the user’s language preference. That preference is detected by the language property of the RequestLocale component. Notice that the dsp:page tags surround the body of the JSP. Only the page directive that defines the tag library precedes the dsp:page tags.

 
loading table of contents...