There are many useful variables in the Portal Object, most of them defined in scheme%portal&. The exhausted list of all Portal Object variables can be obtained by <bee tag="pt%dumpobj">. (<bee:include "common/obj.bs"> is required.)
Site, Path and Page: The Site URL is assumed to be http://hostname/subpath/ and if there is no subpath http://hostname/. Slashes are important.
- {pt%SiteName} - {scheme%SiteName}
- {pt%SiteURL} - The Site URL
- {pt%rt} - "/subpath/" or ("/" if there is no subpath); e.g. src="${pt%rt}images/pict.jpg"
- {pt%SP} - /path/to/current/page.htm
- {pt%PP} - /subpath/path/to/current/page.htm (or same as {pt%SP} if there is no subpath)
- {pt%Subpath} - "/subpath" (or "" if there is no subpath)
- {pt%IncludeRoot} - "subpath/" (or "" if there is no subpath); e.g. include "{pt%IncludeRoot}inc/file.bs";
- {pt%TextSubdir} - Text subdirectory (e.g. for content versioning)
- {pt%DirectoryIndex} - {scheme%portal&DirectoryIndex} (default "index.htm")
Menus and Page Bar: Othe forms of menu
- {pt%PathMenu} - The path menu to the current page
- {pt%PageInfo} - The Menu Record: Parent, Topic, Name, Description, AccessLevel, Page
- {pt%PageBar} - The Page Bar proper
- {pt%PageBarHref} - The "href" attributes of the links on the page bar (Page number is indexed by @n, where n is the page number.)
- {pt%PageBarTitle} - The "title" attributes of the links on the page bar (Page number is indexed by @n, where n is the page number.)
- {pt%PageNumber} - The page number (e.g. 5 for page_5.htm)
- {pt%NumberOfPages} - The total number of pages in the topic
- {pt%ListMenu} - A hierarchy of page links leading to the current page.
- {pt%PrevMenu} - The Menu Record of the previous page
- {pt%NextMenu} - The Menu Record of the next page
- {pt%MenuSelectOptionTags:Page} - A serious of <option> tags that contains the "Page" field of the Menu Record, with the "Name" field as caption.
- {pt%MenuSelectOptionTags:Topic} - A serious of <option> tags that contains the "Topic" field of the Menu Record, with the "Name" field as caption.
- {pt%MenuItemsJS:} - The JavaScript of the loaded Menu Records (from <script> to </script>
Authentication:
- {pt%AuthStatus} - Error code for a login failure (or 0 if otherwise)
- {pt%AuthMessage} - Error message for a login failure (or "" if otherwise)
- {pt%JustLoggedIn} - True if it is the first page to display after a successful login
- {pt%JustLoggedOut} - True if it is the first page to display after a successful logout
Misc:
- {pt%Layout} - {scheme%portal&Layout}
- {pt%SessionTimeout} - {scheme%portal&SessionTimeout}
- {pt%IdleTimeout} - {scheme%portal&IdleTimeout}
- {pt%Phantom} - {scheme%portal&Phantom}
- {pt%DefaultText} - {scheme%portal&DefaultText} (default is <span class="error">Page not found or under construction</span>)
- {pt%DefaultTextPage} - {scheme%portal&DefaultTextPage} (default is /notfound.htm)
Menu Records in JavaScript: The following JavaScript arrays is addressed by the "Topic" field of the Menu Record.
- ItemParent
- ItemName
- ItemDescription
- ItemPage
- ItemParam
- ItemAccessLevel
- ItemIsMenu
- ItemLevel
- ItemPosition
- ItemsChildren = new Array;
|