+

Search Tips   |   Advanced Search

The render URL plug-in

Use the RenderURL rendering plug-in to create URLs that set or remove render parameters.

Syntax:

[Plugin:RenderURL copyCurrentParams="" 
    escape="" 
    uri="" 
    uriMode=""  
    prefix.key="" 
    prefix.value="" 
    prefix.mode="" 
    prefix.type=""]
Attributes:

    copyCurrentParams
    Use this attribute to determine whether we want the current portal state, and the parameters that are encoded in the state to be copied into the new URL. Valid values are true and false. Default is false.

    escape
    Use this attribute to define the escaping used to write the URL. Specify one of the following values: xml, json, javascript, or none. The default is xml.

To set, add, or remove public or private render parameters, use the following attributes. Use the prefix before the attributes to correlate key, value, type, and mode attributes that refer to the same render parameter. The prefix must not contain a period character ( . ).

    prefix.key
    Set the name of the parameter. For the value, specify the simple identifier of a private or public parameter.

    Limited support for non-declared public render parameters: IBM Digital Data Connector also provides limited support for public parameters that are not declared in the Web Content Viewer deployment descriptor. We can identify such parameters by the fully qualified name in the format {ns}localname. Non-declared public render parameters do not work when we use them with WSRP. They are not included by default in the portlet fragment cache key if portlet fragment caching is enabled.

    prefix.value
    Set, add, or remove values for a parameter. The prefix must match the one set for the key listed earlier. To set parameters with multiple values, add multiple prefix.value attributes to the rendering plug-in tag.

    prefix.type
    Use this attribute to determine the type of parameter to be set. Valid values are private and public.

    prefix.mode
    Use this attribute to determine what to do with the parameter values. Valid values for this attribute are as follows:

      set
      This mode is the default mode. Use this mode to set the value for the parameter. When we use this mode, the parameter value set replaces an existing value.

      add
      Use this mode to add a value for the parameter. When we use this mode, the parameter value set is added to existing values. If we use this mode, but no parameter values exist already, a new parameter is set.

      remove
      Use this mode to delete the parameter or its values. Use this mode only for private render parameters with copyCurrentParams="true" or for public render parameters. Use this mode in either of two ways:

      • To completely remove the parameter, pass no values at all.

      • To remove only specific values of a render parameter, pass only the values to remove.

To target a portal resolver plug-in, use the following attributes. If we also specify public render parameters, these parameters are applied after the resolution is completed.

    uri
    Set a valid URI that identifies the resource to be resolved.

    uriMode
    Specify the resolution mode. Valid values are view and download. The plug-in evaluates the uriMode attribute only if no public render parameters are set in the same rendering plug-in tag.

To additionally include parameters for the resolver only, use one of the following attributes:

    prefix.type="uri"
    Specify the type of the parameter to identify it as a resolver parameter.

    prefix.key
    Set the name of the parameter for the resolver. Prefix can be any string

    prefix.value
    Set the value of the parameter for the resolver. To set parameters with multiple values, add the multiple value attributes to the rendering plug-in tag


Examples

All these attributes can be combined together. Examples:

  • The following plug-in tag creates a URL that completes the following two actions:

    • It sets a private render parameter private1.

    • It adds multiple values [pv1, pv2] for the public render parameter public1.

    [Plugin:RenderURL copyCurrentParams="true"      
        pr1.key="private1" 
        pr1.value="v1"
        pr1.type="private"
        pr1.mode="set"
        pr2.key="public1"
        pr2.value="pv1"
        pr2.value="pv2"
        pr2.type="public"
        pr2.mode="add"] 

  • The following plug-in tag creates a URL that completes the following two actions:

    • It sets a public render parameter with multiple values using the qualified name (QName)

        {http://ibm.com}prp1

      ...of the parameter.

    • It removes the private render parameter with the name private1.

    [Plugin1:RenderURL copyCurrentParams="true"      pr1.key="private1" pr1.type="private" pr1.mode="remove"
        pr2.key="{http://ibm.com}prp1" pr2.value="pv1" pr2.value="pv2"      pr2.type="public"  pr2.mode="set"]

  • The following plug-in tag creates a URL that completes the following two actions:

    • It resolves the URI to a page identified by the URI parameter.

    • It adds the value for the public render parameter using the qualified name (QName) {http://ibm.com}prp1 of the parameter on the page that was resolved in the previous step. It sets the value to pv1.

    [Plugin:RenderURL copyCurrentParams="true"
        uri="nm:oid:pageid"
        pr2.key="{http://ibm.com}prp1"
        pr2.value="pv1"
        pr2.type="public" pr2.mode="add"] 


Parent Digital data connector rendering plug-ins


Related information


Package com.ibm.portal.resolver.data summary