Questions answered by this recipe
How do I make a group title, the way I can make a page title?
This section is optional; use it to indicate the types of questions (if any) this recipe is intended to answer.
Creates page variables $GroupTitle and $GroupTitlespace, and page link markup to read group titles
Copy the php file to the cookbook directory, and add
to your config.php file.
Administrators add Group Titles to a Site.GroupTitles page as Page Text Variables, in the format
(...or any other Page Text Variable format). So if the group "ParkCenter" wanted to be shown to the user as "Center of the Park", the administrator would make an entry
on a separate line on the Site.GroupTitles page. (The page containing the group titles page text variables can be specified by assigning a page name to $GroupTitlesPageFmt).
Subsequently the Group Title is available in the Page Variables $GroupTitle and $GroupTitlespaced, and the Group Titles can be put into page links with
In the example
[[ParkCenter.ParkCenter|!+]] would show up as a link with the text "Center of the Park".
This markup is particularly useful in Page List Templates.
So page titles and group titles now have exact analogues:
- Page titles have $Title and $Titlespaced page variables,
and the markup
set by (:title:)
- Group titles have $GroupTitle and $GroupTitlespaced page variables,
and the markup
set by page text variable entries in Site.GroupTitles
- First release, beta
- Stable release
If the recipe has multiple releases, then release notes can be placed here. Note that it's often easier for people to work with "release dates" instead of "version numbers".
GroupTitle by Pm