In Tiki 6, the feature has been enhanced to make it possible to redirect all pages with a certain prefix to a particular page, which when used in conjunction with an itemId after the prefix, is useful for pages with Pretty Trackers. For example, to redirect links like Project:256 or Project:32 to the page "Projects" which is a pretty tracker page, the following can be added to the View Project page. Put it inside Tiki comments to hide it from view if necessary.
Prefix Alias operates similar to Apache mod_rewite. Using "prefixalias" configuration as described below it is possible to have Tracker Item links rewritten and automatically redirect to display the item in your Pretty Tracker Pages.
Copy to clipboard (prefixalias(Project:))
First thing the prefixes that are to be allowed should be set first under Admin...Wiki (by the admin.)
Minimal usage on a wiki page (ex.: on page "Project")
Copy to clipboard (prefixalias(Project:))
(trackerid(3))
Where "Project:" is replaced with the actual wiki page (destination) for the link rewrite, trackerid(3) specifies which tracker links will be rewritten. That is the minimum required (in addition to entering the prefix under Admin...Wiki as above.)
Extended usage on a wiki page (ex.: on page "Resource")
Copy to clipboard (prefixalias(Resource:))
(trackerid(3))
(fieldid(12))
Where adding fieldid(12) allows matching of a specific tracker field when using the field 'value' in your prefix alias.
Example: Inserting ((Resource:Categories Revamp Project)) into the wiki page will automatically display a link to the Resource item with that title (in field 12 for tracker 3).
If the part of the link after the pagename is an integer it will automatically become the itemId in the query string. So for example a link to /Resource256 becomes a link to /Resource?itemId=256. This allows automatic generation of links to your pretty tracker pages for displaying your tracker items.
|