Please make sure you have read the Tag Syntax document and understand how tag attribute syntax works.

The id attribute is deprecated in Struts 2.1.x, and has been replaced by the var attribute.

Description

Error formatting macro: snippet: java.lang.NullPointerException

Setting a default value for includeParams

The property struts.url.includeParams can be used to set the default value of the includeParams attribute.

Setting the default value of includeParams
<struts>
   ...
   <constant name="struts.url.includeParams" value="none" />
   ...
</struts>

See Constant Configuration for further information.

As of Struts 2.1.3 the includeParams constant defaults to "none".

Parameters

Error formatting macro: snippet: java.lang.NullPointerException

Examples

Error formatting macro: snippet: java.lang.NullPointerException
  • No labels

4 Comments

  1. Change "overriden" to "overridden".
    Change "exists" to "exist".
    Change the two URLs under "Description" to valid URLs.
    Change "cause" to "because".
    Change "he action generate url for, if not using value" to "The action to generate url for, if not using value".
    Change "&lt" to <" in the last code sample.

  2. To the description of the "method" parameter ("The method of action to use"), add the following:

    the "action" parameter must also be present in order for the "method" parameter to work, even if the url points to the same action as the current one.

  3. Both in the "Description" and "Parameters" sections, the final 'semi-column'+'right-parenthesis' after '&amp' are mistakenly parsed (by the wiki engine I guess) as an emoticon. Moreover, it looks like the corresponding image is not available. A quick workaround would be to add a space between the semi-column and the right parenthesis.

  4. Please add to the description for includeContext:

    The value attribute is required when using the includeContext attribute.

    If the action & value attributes are omitted, the context will be included regardless of the settings in includeContext.