Suggestion #9157
Is title setting via JS really needed?
| Status: | Accepted | Start date: | 2010-08-05 | |
|---|---|---|---|---|
| Priority: | Could have | Due date: | ||
| Assignee: | Kai Vogel | % Done: | 0% |
|
| Category: | General | Spent time: | - | |
| Target version: | - | |||
| Votes: | 0 |
Description
If you using a extension for displaying "virtual" pages the function sGetTitle wont find any title and JS is used to get the title out of the page directly.
Its possible to use
return $GLOBALS['TSFE']->page['title']);
instead, which always finds a title (or description or subtitle).
Problem is we cant use TS like subtitle // title. This could be fixed by using a array like:
pageTitle.0 = subtitle pageTitle.1 = title
This way we save a loop trough all links via JS in FE and a DB query.
At least there should be added a fallback using
$GLOBALS['TSFE']->page['title']);
if page is generated via extension aka is not in pages DB table and sGetTitle wont find anything.
History
Updated by Kai Vogel almost 3 years ago
- Category set to General
- Status changed from New to Accepted
- Assignee set to Kai Vogel
I'll check and implement an extended (and more TYPO3-like) way to get the title via TypoScript. But the possibility to get the title via JavaScript will also be available in next version.
Updated by Felix Nagel almost 3 years ago
Thats fine for me, but you should be implement it as a progressive enhancement not as a must have like in the current version.
Would be nice to have an option to disable JS.