You are here: Reference > Streams and JSP > JavaServer Pages tags > withPage

  withPage JavaServer Page tag

Use the withPage tag to replace the primary page with a different page (the base page) throughout a segment of the HTML or XML text, as a coding convenience. The new page applies only to HTML or XML code within the body of the withPage tag.

Example

For example, the reference tag refers to property pyWorkPage.pyStatusWork:

<pega:withPage name="pyWorkPage">
      and your application status is:
      <pega:reference name=".pyStatusWork" />
</pega:withPage>

Complete syntax

In the syntax presentation below:

<pega:withPage name="pagename">
<!-- HTML and/or tags here with pagename as the base page -->

</pega:withPage>

The name attribute is required. The page you identify must also appear in the
Pages & Classes tab of the current rule.

Attribute

Value

name A clipboard page name, which may include the keyword $this.

Examples:

  • Reference to a property of mode Page
  • $this — for the current page
  • $this.pagename — for an embedded page in the current page
Definitions base page

About JavaServer Page tags