‪TYPO3CMS  11.5
PageTreeView.php
Go to the documentation of this file.
1 <?php
2 
3 /*
4  * This file is part of the TYPO3 CMS project.
5  *
6  * It is free software; you can redistribute it and/or modify it under
7  * the terms of the GNU General Public License, either version 2
8  * of the License, or any later version.
9  *
10  * For the full copyright and license information, please read the
11  * LICENSE.txt file that was distributed with this source code.
12  *
13  * The TYPO3 project - inspiring people to share!
14  */
15 
17 
19 
24 {
32  public function ‪init(‪$clause = '', ‪$orderByFields = '')
33  {
34  parent::init(' AND deleted=0 AND sys_language_uid=0 ' . ‪$clause, ‪$orderByFields ?: 'sorting');
35  }
36 
43  public function ‪expandNext($id)
44  {
45  return true;
46  }
47 
61  public function ‪PMicon($row, $a, $c, $nextCount, $isExpand)
62  {
63  return '<span class="treeline-icon treeline-icon-join' . ($a == $c ? 'bottom' : '') . '"></span>';
64  }
65 
74  public function ‪getTitleStr($row, $titleLen = 30)
75  {
76  $lang = $this->‪getLanguageService();
77  ‪$title = htmlspecialchars(GeneralUtility::fixed_lgd_cs($row['title'], $titleLen));
78  if (isset($row['nav_title']) && trim($row['nav_title']) !== '') {
79  ‪$title = '<span title="'
80  . htmlspecialchars($lang->sL('LLL:EXT:frontend/Resources/Private/Language/locallang_tca.xlf:pages.nav_title'))
81  . ' ' . htmlspecialchars(trim($row['nav_title'])) . '">' . ‪$title
82  . '</span>';
83  }
84  return trim($row['title']) === ''
85  ? '<em>[' . htmlspecialchars($lang->sL('LLL:EXT:core/Resources/Private/Language/locallang_core.xlf:labels.no_title')) . ']</em>'
86  : ‪$title;
87  }
88 }
‪TYPO3\CMS\Backend\Tree\View\PageTreeView\PMicon
‪string PMicon($row, $a, $c, $nextCount, $isExpand)
Definition: PageTreeView.php:61
‪TYPO3\CMS\Backend\Tree\View\AbstractTreeView\$clause
‪string $clause
Definition: AbstractTreeView.php:75
‪TYPO3\CMS\Backend\Tree\View\AbstractTreeView\$title
‪string $title
Definition: AbstractTreeView.php:48
‪TYPO3\CMS\Backend\Tree\View\PageTreeView
Definition: PageTreeView.php:24
‪TYPO3\CMS\Backend\Tree\View\PageTreeView\expandNext
‪bool expandNext($id)
Definition: PageTreeView.php:43
‪TYPO3\CMS\Backend\Tree\View\AbstractTreeView\$orderByFields
‪string $orderByFields
Definition: AbstractTreeView.php:82
‪TYPO3\CMS\Backend\Tree\View
Definition: AbstractContentPagePositionMap.php:18
‪TYPO3\CMS\Backend\Tree\View\AbstractTreeView\getLanguageService
‪LanguageService getLanguageService()
Definition: AbstractTreeView.php:581
‪TYPO3\CMS\Backend\Tree\View\PageTreeView\init
‪init($clause='', $orderByFields='')
Definition: PageTreeView.php:32
‪TYPO3\CMS\Backend\Tree\View\PageTreeView\getTitleStr
‪string getTitleStr($row, $titleLen=30)
Definition: PageTreeView.php:74
‪TYPO3\CMS\Core\Utility\GeneralUtility
Definition: GeneralUtility.php:50
‪TYPO3\CMS\Backend\Tree\View\AbstractTreeView
Definition: AbstractTreeView.php:37