D.2 <form:if-item-exists>

The <form:if-item-exists> element is used to conditionally insert data into the output document. The content of <form:if-item-exists> is processed only if the specified item appears in the replacement data.


Name: Specifies the name of the replacement data item. If one or more examples of the replacement data item exist, then the contents of the <form:if-item-exists> element are processed.


<form:if-item-exists name="post-status-message">
          Status message was: $post-status-message$

This example inserts a row into an HTML table only if there is a replacement data item named post-status-message.