Add the inline tag widget to the portal content
By default the inline tag widget is available for WCM content and blogs and wikis. We can also add inline tag widgets to the portal content as required.To include an inline tag widget in a page or a portlet or other content, insert the following HTML snippet into the jsp or other code:
<div id="unique_ID" > <div dojoType="com.ibm.widgets.InlineTag" resourceID="my_ID" resourceTitle=”my_Title” tagScope="all|community|personal|personal_public|personal_private|community_personal_public" resourceType="NAVIGATION_NODE|CONTENT_NODE"> </div> </div>The parameters have the following meaning:
- id = unique_ID
- Use this attribute to specify a unique ID for parsing all surrounding <div> tags to enable the widgets
- resourceID
- Specify the identifier of the piece of content that will show the widget. This needs to be unique.
For example, for a portal page specify the portal object ID on that page.
- resourceTitle
- Title of the piece of content. This title string is passed to the dialog box when the user opens it to add new tags. If you do not want the dialog box to show a title, we can omit the value for this parameter.
- resourceType = NAVIGATION_NODE | CONTENT_NODE
- Type of the resource for which the rating widget is called. This parameter is mandatary only for portal resources such as pages or portlets. Valid values are NAVIGATION_NODE or CONTENT_NODE .
These parameters are mandatary. For information about the optional parameters refer to the topic about Inline tag widget parameter reference.
To actually enable the widgets, you need to parse the surrounding <div> tag within your jsp using the following code:
dojo.addOnLoad(function(){ dojo.forEach(["uniqueID1", "uniqueID2", …], dojo.parser.parse, dojo.parser); });
Parent: The inline tag widget