+

Search Tips   |   Advanced Search


URL generation using PathCmpnt and URLCmpnt tags

There are some special considerations to keep in mind when using URLCmpnt and PathCmpnt tags to create URLs to other Web content items from within your content.


Use the URLCmpnt tag

The URL component tag URLCmpnt can be used to create URLs to content items in a presentation template. If the attribute mode="portal" is set, the content item is displayed through a content viewer portlet. URLs to the JSR 286 Web Content Viewer differ from URLs to the traditional Web Content Viewer. When the URLCmpnt tag is used in content rendered in the JSR 286 Web Content Viewer, the tag creates URLs in an updated format that the portlet understands. When the tag is used from a traditional Web Content Viewer, the tag creates URLs in the older format. This means that the URLCmpnt tag cannot be used to link from the traditional Web Content Viewer to the JSR 286 Web Content Viewer or vice versa.


Use the PathCmpnt tag

The path component is used to create the base part of a URL in Web content. Typically, the base part is extended by some string that identifies the content to be displayed. If the path component is used inside the context of a JSR 286 Web Content Viewer, the generated URL has the updated URL format and thus cannot be displayed with the traditional Web Content Viewer.


Add URL parameters

Adding URL parameters to a regular portal URL will not affect the JSR 286 Web Content Viewer. For this purpose use the URLCmpnt or PathCmpnt tag. Additional URL query parameters, like those used with the traditional Web Content Viewer, can be appended to the URLs generated by these tags.


Parent topic:

Web content creation features