The portal now supports navigation based on short, or hashed, URLs. In other words, instead of a long URL, such as the following:
the portal creates another URL for the same navigation target such as the following:
This feature reduces network traffic by shortening the URL, enables better use of the broswer cache, and supports HTTP Get requests. An administrator can turn this feature on, and then the navigation service creates hashed URLs for all navigation nodes. All links created by the navigation service are generated as hashed URLs and not as the original, long URL. You do not have to do anything to have the navigation service create hashed URLs for your connector. If the feature is turned on, the hashing occurs automatically. By default, the feature is turned on. There is no real reason for turning this feature off. For more information on short URLs, see Navigation with Short URLs in the Portal Developer Guide on the Help Portal.
The portal now comes with a Navigation node under the System Administration role that includes a page for turning on and off the short URLs feature, as well as for viewing all short URLs and the navigation nodes to which each corresponds. For each navigation node, you can see its URL with a ROLES prefix and its short URL, which you would use with a navurl prefix. To be honest, there’s not much to do here if everything is working OK.
The Navigation API has been updated so you can retrieve both the long (original) and short URLs of a navigation node (INavigationNode):
- getHashed(): Returns the short (hashed) URL. If the hashed URL feature is turned off, this method returns the long URL.
- getName(): Returns the long URL.
The following are the weblogs in the series on External Facing Portal:
- Nuts and Bolts of the External Facing Portal (EFP)
- EFP: Navigation and Framework Tag Libraries
- EFP: Layout Tag Library
- EFP: Navigation Caching
- EFP: Quick Links
- EFP: Short URLs