Person’s Contacts on the Page
- CType
-
academiccontacts4pages_list - Plugin
-
Academic, pluginContacts4pages List, actionContactsController:: list Action () - Set
-
fgtclb/, which the aggregate setacademic- contacts4pages- list fgtclb/includes, see What the sets containacademic- contacts4pages
Person’s Contacts on the Page shows the contact persons of a page: the dean's office on the page of a faculty, the participants on the page of a research project, the student advisers on the page of a study programme. Each contact is rendered as the card of a profile of academic_persons, with the image, the name, the position and the e-mail addresses, phone numbers and addresses of the contract the contact names. The contacts are grouped below the names of their roles.
The start of a contact list grouped by role: the first two role groups, each with its heading. The contacts without a role follow below the last group.
It is the element for contact persons in the content area of a page. A page layout that shows them in a sidebar or a panel uses the data processor of The contacts in a page template instead, which reads the same contacts.
Where the contacts come from
The editor assigns contacts in the tab Contacts of a page, or in the tab Linked pages of a contract, see Contact records. Each contact names a contract of a person, an optional role, and which of the e-mail addresses, phone numbers and addresses of the contract to display.
The content element shows the contacts of the page it is stored on, in the order they are sorted on that page. Put it on the page that carries the contacts. A content element shown on another page, through an Insert records element for example, still shows the contacts of its own page. A contact is left out while the contract or the profile behind it is not visible in the frontend.
What it renders
Each contact is rendered through the partial Contacts/ of
this extension, which renders the profile card of academic_persons,
see The contact item partial. The name links to the profile
detail page that the constant
plugin. of
academic_persons names. Whether the names link at all follows the
setting
plugin. of
academic_persons, Link the names to the detail view of
its site set: with none, for a site without profile detail pages, the names
of the contacts are shown as text, as in the persons elements. The content
element has no option of its own for it. A site that shows the names without a
link in the persons elements and wants them linked here sets the plugin
setting of this extension in its TypoScript setup:
plugin.tx_academiccontacts4pages.settings.detailLink = link
The crop variant and the placeholders of the image and the prefix of the phone links come from the constants of academic_persons as well, see the note in What the sets contain.
The headings of the roles take their level from the header layout of the content element. The element is cached with the page. Saving the contacts in the form of their page clears the cache of that page.
Related chapters:
- Styling describes the markup. The extension ships no stylesheet.
- The header of the content elements is for a site whose content element layout renders no header.
Settings
The tab Configuration of the content element holds two options.
-
- Type
- checkbox
- Default
- on
Whether the contacts are grouped below the names of their roles.
- On: one heading per role, each followed by the contacts of that role, then the contacts without a role. The roles follow each other in the order in which they first occur among the contacts of the page. A page on which no contact has a role renders one list without headings.
- Off: all contacts in one list, in the order they are sorted on the
page. A contact with a role shows its role name above its card, in an
element with the class
ace-.role
Switch it off where the order of the contacts matters more than their roles, or where every contact has a role of its own and a heading per person would repeat the card.
A content element saved before the option existed stores no value for it and reads the TypoScript default, so it keeps grouping:
Shipped TypoScript setupplugin.tx_academiccontacts4pages.settings.groupByRole = 1Copied!A value stored in the content element always wins over it.
The contacts without grouping: the role name stands above each card. The element of the development instance has Show hidden records switched on as well, as its header says: one of the two contacts is hidden and is shown only because of that option.