View Source Return to examples page

Logic Tags Example


Present / Not Present

Cookie

UNKNOWN cookie is not present.

Parameter

Parameter 'param' not present. Redisplay page with parameter present.

Bean

'testBean' is present.

'anotherTestBean' is not present.

'fred' property is not present on 'testBean'

'stringValue' property is present on 'testBean'

Empty / Not Empty

'items' was found.

'items' is empty

Comparison tags

intValue == 7

intValue >= 7

intValue >= 6

intValue > 6

intValue <= 7

intValue <= 8

intValue < 8

stringValue matches 'world'

stringValue does not match 'earth'

Iteration

Book list:

  1. Programming Jakarta Struts
  2. Struts in Action
  3. Professional Struts Applications
  4. Struts Kick Start
  5. Mastering Jakarta Struts
  6. The Struts Framework
  7. Struts Fast Track

Book list (entries 3-5):

  1. Professional Struts Applications
  2. Struts Kick Start
  3. Mastering Jakarta Struts

Checking for and displaying messages

Errors:

Global errors:

Errors for 'test':

Messages:

Messages for 'test':