33 class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRecordList {
82 public $agePrefixes =
' min| hrs| days| yrs| min| hour| day| year';
116 'showSingleCol' => 0,
120 'languageColsPointer' => 0,
123 'sys_language_uid' => 0,
126 'activeCols' =>
'1,0,2,3' 140 'nextThree' => array(),
195 if (isset($this->externalTables[
$table])) {
204 return $this->getTable_tt_content(
$id);
226 $fList = $this->externalTables[
$table][$type][
'fList'];
229 $icon = $this->externalTables[
$table][$type][
'icon'];
230 $addWhere = $this->externalTables[
$table][$type][
'addWhere'];
259 if (is_array($row)) {
264 $this->fieldArray = array(
'title',
'uid') + array_keys($this->
cleanTableNames());
267 $this->fieldArray = array(
282 $this->fieldArray = array(
300 $out .= $this->addelement(0,
'', $theData);
302 $this->no_noWrap = 0;
303 $this->oddColumnsCssClass =
'bgColor3-20';
315 $editUids[] = $row[
'uid'];
319 foreach ($theRows as $sRow) {
321 $editUids[] = $sRow[
'uid'];
329 $editIdList = implode(
',', $editUids);
331 foreach ($this->fieldArray as $field) {
332 if ($editIdList && isset(
$GLOBALS[
'TCA'][
'pages'][
'columns'][$field]) && $field !=
'uid' && !$this->pages_noEditColumns) {
333 $params =
'&edit[pages][' . $editIdList .
']=edit&columnsOnly=' . $field .
'&disHelp=1';
345 $theData[$field] =
' <strong>' 350 $theData[$field] =
' <strong>ID:</strong>';
353 if (substr($field, 0, 6) ==
'table_') {
354 $f2 = substr($field, 6);
361 $theData[$field] =
' <strong>' 368 $this->oddColumnsCssClass =
'';
371 <table border="0" cellpadding="0" cellspacing="0" class="typo3-page-pages"> 372 ' . $this->addelement(1,
'', $theData,
' class="t3-row-header"', 20) . $out .
' 375 $this->oddColumnsCssClass =
'';
398 public function getTable_tt_content(
$id) {
408 $pageRenderer->loadExtJs();
409 $pageRenderer->addJsFile(
$GLOBALS[
'BACK_PATH'] .
'sysext/cms/layout/js/typo3pageModule.js');
411 $this->CType_labels = array();
412 foreach (
$GLOBALS[
'TCA'][
'tt_content'][
'columns'][
'CType'][
'config'][
'items'] as $val) {
415 $this->itemLabels = array();
416 foreach (
$GLOBALS[
'TCA'][
'tt_content'][
'columns'] as $name => $val) {
419 $languageColumn = array();
423 if (!$this->tt_contentConfig[
'single']) {
425 $langList = $this->tt_contentConfig[
'sys_language_uid'];
426 if ($this->tt_contentConfig[
'languageMode']) {
427 if ($this->tt_contentConfig[
'languageColsPointer']) {
428 $langList =
'0,' . $this->tt_contentConfig[
'languageColsPointer'];
430 $langList = implode(
',', array_keys($this->tt_contentConfig[
'languageCols']));
432 $languageColumn = array();
435 $defLanguageCount = array();
439 foreach ($langListArr as $lP) {
441 if (count($langListArr) === 1 || $lP === 0) {
442 $showLanguage =
' AND sys_language_uid IN (' . $lP .
',-1)';
444 $showLanguage =
' AND sys_language_uid=' . $lP;
450 if (!empty($cList)) {
454 foreach ($cList as $key) {
456 $defLanguageCount[$key] = array();
459 $content[$key] .=
'<div class="t3-page-ce-wrapper';
460 if (count($contentRecordsPerColumn[$key]) === 0) {
461 $content[$key] .=
' t3-page-ce-empty';
463 $content[$key] .=
'">';
466 <div class="t3-page-ce" id="' . str_replace(
'.',
'', uniqid(
'', TRUE)) .
'"> 467 <div class="t3-page-ce-dropzone" id="colpos-' . $key .
'-' .
'page-' .
$id .
'-' . uniqid(
'', TRUE) .
'"> 468 <div class="t3-page-ce-wrapper-new-ce"> 477 $rowArr = $contentRecordsPerColumn[$key];
479 foreach ((array)$rowArr as $rKey => $row) {
480 if ($this->tt_contentConfig[
'languageMode']) {
481 $languageColumn[$key][$lP] = $head[$key] . $content[$key];
482 if (!$this->defLangBinding) {
490 $singleElementHTML =
'';
491 if (!$lP && ($this->defLangBinding || $row[
'sys_language_uid'] != -1)) {
492 $defLanguageCount[$key][] = $row[
'uid'];
494 $editUidList .= $row[
'uid'] .
',';
495 $disableMoveAndNewButtons = $this->defLangBinding && $lP > 0;
496 if (!$this->tt_contentConfig[
'languageMode']) {
497 $singleElementHTML .=
'<div class="t3-page-ce-dragitem" id="' . str_replace(
'.',
'', uniqid(
'', TRUE)) .
'">';
501 $this->tt_contentConfig[
'showInfo'] ? 15 : 5,
502 $disableMoveAndNewButtons,
504 !$this->tt_contentConfig[
'languageMode']
506 $isRTE = $RTE && $this->
isRTEforField(
'tt_content', $row,
'bodytext');
507 $innerContent =
'<div ' . ($row[
'_ORIG_uid'] ?
' class="ver-element"' :
'') .
'>' 509 $singleElementHTML .=
'<div class="t3-page-ce-body-inner">' . $innerContent .
'</div>' 513 $singleElementHTML .=
'</div>';
514 $statusHidden = $this->
isDisabled(
'tt_content', $row) ?
' t3-page-ce-hidden' :
'';
515 $singleElementHTML =
'<div class="t3-page-ce' . $statusHidden .
'" id="element-tt_content-' 516 . $row[
'uid'] .
'">' . $singleElementHTML .
'</div>';
517 if ($this->tt_contentConfig[
'languageMode']) {
518 $singleElementHTML .=
'<div class="t3-page-ce">';
520 $singleElementHTML .=
'<div class="t3-page-ce-dropzone" id="colpos-' . $key .
'-' .
'page-' .
$id .
521 '-' . str_replace(
'.',
'', uniqid(
'', TRUE)) .
'">';
523 if (!$disableMoveAndNewButtons) {
525 if ($this->option_newWizard) {
526 $onClick =
'window.location.href=\'db_new_content_el.php?id=' . $row[
'pid']
527 .
'&sys_language_uid=' . $row[
'sys_language_uid'] .
'&colPos=' . $row[
'colPos']
528 .
'&uid_pid=' . -$row[
'uid'] .
531 $params = '&edit[tt_content][
' . -$row['uid
'] . ']=
new'; 532 $onClick = BackendUtility::editOnClick($params, $this->backPath); 534 $singleElementHTML .= ' 535 <div
class=
"t3-page-ce-wrapper-new-ce">
536 <a href=
"#" onclick=
"' . htmlspecialchars($onClick) . '" title=
"' 537 . $this->getLanguageService()->getLL('newRecordHere', TRUE) . '">
' 538 . IconUtility::getSpriteIcon('actions-document-
new') . '</a>
542 $singleElementHTML .= '</div></div>
'; 543 if ($this->defLangBinding && $this->tt_contentConfig['languageMode
']) { 544 $defLangBinding[$key][$lP][$row[$lP ? 'l18n_parent
' : 'uid
']] = $singleElementHTML; 546 $content[$key] .= $singleElementHTML; 549 unset($rowArr[$rKey]); 552 $content[$key] .= '</div>
'; 553 // Add new-icon link, header: 554 $newP = $this->newContentElementOnClick($id, $key, $lP); 555 $colTitle = BackendUtility::getProcessedValue('tt_content
', 'colPos
', $key); 556 $tcaItems = GeneralUtility::callUserFunction('TYPO3\\CMS\\Backend\\View\
\BackendLayoutView->getColPosListItemsParsed
', $id, $this); 557 foreach ($tcaItems as $item) { 558 if ($item[1] == $key) { 559 $colTitle = $this->getLanguageService()->sL($item[0]); 563 $pasteP = array('colPos
' => $key, 'sys_language_uid
' => $lP); 564 $editParam = $this->doEdit && count($rowArr) 565 ? '&edit[tt_content][
' . $editUidList . ']=edit
' . $pageTitleParamForAltDoc 567 $head[$key] .= $this->tt_content_drawColHeader($colTitle, $editParam, $newP, $pasteP); 570 // For each column, fit the rendered content into a table cell: 572 if ($this->tt_contentConfig['languageMode
']) { 573 // in language mode process the content elements, but only fill $languageColumn. output will be generated later 574 $sortedLanguageColumn = array(); 575 foreach ($cList as $key) { 576 $languageColumn[$key][$lP] = $head[$key] . $content[$key]; 577 if (!$this->defLangBinding) { 578 $languageColumn[$key][$lP] .= $this->newLanguageButton( 579 $this->getNonTranslatedTTcontentUids($defLanguageCount[$key], $id, $lP), 583 // We sort $languageColumn again according to $cList as it may contain data already from above. 584 $sortedLanguageColumn[$key] = $languageColumn[$key]; 586 $languageColumn = $sortedLanguageColumn; 588 $backendLayout = $this->getBackendLayoutView()->getSelectedBackendLayout($this->id); 590 $grid = '<div
class=
"t3-gridContainer"><table border=
"0" cellspacing=
"0" cellpadding=
"0" width=
"100%" height=
"100%" class=
"t3-page-columns t3-gridTable">
'; 592 $colCount = (int)$backendLayout['__config
']['backend_layout.
']['colCount
']; 593 $rowCount = (int)$backendLayout['__config
']['backend_layout.
']['rowCount
']; 594 $grid .= '<colgroup>
'; 595 for ($i = 0; $i < $colCount; $i++) { 596 $grid .= '<col style=
"width:' . 100 / $colCount . '%"></col>
'; 598 $grid .= '</colgroup>
'; 599 // Cycle through rows 600 for ($row = 1; $row <= $rowCount; $row++) { 601 $rowConfig = $backendLayout['__config
']['backend_layout.
']['rows.
'][$row . '.
']; 602 if (!isset($rowConfig)) { 606 for ($col = 1; $col <= $colCount; $col++) { 607 $columnConfig = $rowConfig['columns.
'][$col . '.
']; 608 if (!isset($columnConfig)) { 611 // Which tt_content colPos should be displayed inside this cell 612 $columnKey = (int)$columnConfig['colPos
']; 613 // Render the grid cell 614 $colSpan = (int)$columnConfig['colspan
']; 615 $rowSpan = (int)$columnConfig['rowspan
']; 616 $grid .= '<td valign=
"top"' . 617 ($colSpan > 0 ? ' colspan=
"' . $colSpan . '"' : '') . 618 ($rowSpan > 0 ? ' rowspan=
"' . $rowSpan . '"' : '') . 619 ' class=
"t3-gridCell t3-page-column t3-page-column-' . $columnKey . 620 ((!isset($columnConfig['colPos']) || $columnConfig['colPos'] === '') ? ' t3-gridCell-unassigned' : '') . 621 ((isset($columnConfig['colPos']) && $columnConfig['colPos'] !== '' && !$head[$columnKey]) || !GeneralUtility::inList($this->tt_contentConfig['activeCols'], $columnConfig['colPos']) ? ' t3-gridCell-restricted' : '') . 622 ($colSpan > 0 ? ' t3-gridCell-width' . $colSpan : '') . 623 ($rowSpan > 0 ? ' t3-gridCell-height' . $rowSpan : '') . '">
'; 625 // Draw the pre-generated header with edit and new buttons if a colPos is assigned. 626 // If not, a new header without any buttons will be generated. 628 isset($columnConfig['colPos
']) && $columnConfig['colPos
'] !== '' && $head[$columnKey] 629 && GeneralUtility::inList($this->tt_contentConfig['activeCols
'], $columnConfig['colPos
']) 631 $grid .= $head[$columnKey] . $content[$columnKey]; 633 isset($columnConfig['colPos
']) && $columnConfig['colPos
'] !== '' 634 && GeneralUtility::inList($this->tt_contentConfig['activeCols
'], $columnConfig['colPos
']) 636 $grid .= $this->tt_content_drawColHeader($this->getLanguageService()->getLL('noAccess
'), '', ''); 638 isset($columnConfig['colPos
']) && $columnConfig['colPos
'] !== '' 639 && !GeneralUtility::inList($this->tt_contentConfig['activeCols
'], $columnConfig['colPos
']) 641 $grid .= $this->tt_content_drawColHeader($this->getLanguageService()->sL($columnConfig['name
']) . 642 ' (
' . $this->getLanguageService()->getLL('noAccess
') . ')
', '', ''); 643 } elseif (isset($columnConfig['name
']) && strlen($columnConfig['name
']) > 0) { 644 $grid .= $this->tt_content_drawColHeader($this->getLanguageService()->sL($columnConfig['name
']) 645 . ' (
' . $this->getLanguageService()->getLL('notAssigned
') . ')
', '', ''); 647 $grid .= $this->tt_content_drawColHeader($this->getLanguageService()->getLL('notAssigned
'), '', ''); 654 $out .= $grid . '</table></div>
'; 657 $out .= BackendUtility::cshItem($this->descrTable, 'columns_multi
', $GLOBALS['BACK_PATH
']); 659 // If language mode, then make another presentation: 660 // Notice that THIS presentation will override the value of $out! 661 // But it needs the code above to execute since $languageColumn is filled with content we need! 662 if ($this->tt_contentConfig['languageMode
']) { 663 // Get language selector: 664 $languageSelector = $this->languageSelector($id); 665 // Reset out - we will make new content here: 667 // Traverse languages found on the page and build up the table displaying them side by side: 670 foreach ($langListArr as $lP) { 674 <td valign=
"top" class=
"t3-page-lang-column">
675 <h3>
' . htmlspecialchars($this->tt_contentConfig['languageCols
'][$lP]) . '</h3>
678 // "View page" icon is added: 679 if (!VersionState::cast($this->getPageLayoutController()->pageinfo['t3ver_state
'])->equals(VersionState::DELETE_PLACEHOLDER)) { 680 $onClick = BackendUtility::viewOnClick($this->id, $this->backPath, BackendUtility::BEgetRootLine($this->id), '', '', ('&L=
' . $lP)); 681 $viewLink = '<a href=
"#" onclick=
"' . htmlspecialchars($onClick) . '" title=
"' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.showPage', TRUE) . '">
' . IconUtility::getSpriteIcon('actions-document-view
') . '</a>
'; 683 // Language overlay page header: 685 list($lpRecord) = BackendUtility::getRecordsByField('pages_language_overlay
', 'pid
', $id, 'AND sys_language_uid=
' . $lP); 686 BackendUtility::workspaceOL('pages_language_overlay
', $lpRecord); 687 $params = '&edit[pages_language_overlay][
' . $lpRecord['uid
'] . ']=edit&overrideVals[pages_language_overlay][sys_language_uid]=
' . $lP; 688 $lPLabel = $this->getPageLayoutController()->doc->wrapClickMenuOnIcon( 689 IconUtility::getSpriteIconForRecord('pages_language_overlay
', $lpRecord), 690 'pages_language_overlay
', 692 ) . $viewLink . ($this->getBackendUser()->check('tables_modify
', 'pages_language_overlay
') 693 ? '<a href=
"#" onclick=
"' . htmlspecialchars(BackendUtility::editOnClick($params, $this->backPath)) 694 . '" title=
"' . $this->getLanguageService()->getLL('edit', TRUE) . '">
' 695 . IconUtility::getSpriteIcon('actions-document-open
') . '</a>
' 697 ) . htmlspecialchars(GeneralUtility::fixed_lgd_cs($lpRecord['title
'], 20)); 699 $lPLabel = $viewLink; 702 <td nowrap=
"nowrap" class=
"t3-page-lang-column t3-page-lang-label">
' . $lPLabel . '</td>
'; 705 $out .= '<tr>
' . implode($cCont) . '</tr>
'; 706 $out .= '<tr>
' . implode($sCont) . '</tr>
'; 707 // Traverse previously built content for the columns: 708 foreach ($languageColumn as $cKey => $cCont) { 711 <td valign=
"top" class=
"t3-gridCell t3-page-column t3-page-lang-column">
' . implode(('</td>
' . ' 712 <td valign=
"top" class=
"t3-gridCell t3-page-column t3-page-lang-column">
'), $cCont) . '</td>
714 if ($this->defLangBinding) { 715 // "defLangBinding" mode 716 foreach ($defLanguageCount[$cKey] as $defUid) { 718 foreach ($langListArr as $lP) { 719 $cCont[] = $defLangBinding[$cKey][$lP][$defUid] . $this->newLanguageButton( 720 $this->getNonTranslatedTTcontentUids(array($defUid), $id, $lP), 726 <td valign=
"top" class=
"t3-page-lang-column">
' . implode(('</td>
' . ' 727 <td valign=
"top" class=
"t3-page-lang-column">
'), $cCont) . '</td>
731 $cCont = array_fill(0, count($langListArr), '
'); 734 <td valign=
"top" class=
"t3-page-lang-column">
' . implode(('</td>
' . ' 735 <td valign=
"top" class=
"t3-page-lang-column">
'), $cCont) . '</td>
739 // Finally, wrap it all in a table and add the language selector on top of it: 740 $out = $languageSelector . ' 741 <div
class=
"t3-lang-gridContainer">
742 <table cellpadding=
"0" cellspacing=
"0" class=
"t3-page-langMode">
747 $out .= BackendUtility::cshItem($this->descrTable, 'language_list
', $GLOBALS['BACK_PATH
']); 750 // SINGLE column mode (columns shown beneath each other): 751 if ($this->tt_contentConfig['sys_language_uid
'] == 0 || !$this->defLangBinding) { 753 if ($this->defLangBinding && $this->tt_contentConfig['sys_language_uid
'] == 0) { 754 $showLanguage = ' AND sys_language_uid IN (0,-1)
'; 757 $showLanguage = ' AND sys_language_uid=
' . $this->tt_contentConfig['sys_language_uid
']; 758 $lP = $this->tt_contentConfig['sys_language_uid
']; 760 $cList = explode(',
', $this->tt_contentConfig['showSingleCol
']); 762 // Expand the table to some preset dimensions: 765 <td><img src=
"clear.gif" width=
"' . $lMarg . '" height=
"1" alt=
"" /></td>
766 <td valign=
"top"><img src=
"clear.gif" width=
"150" height=
"1" alt=
"" /></td>
767 <td><img src=
"clear.gif" width=
"10" height=
"1" alt=
"" /></td>
768 <td valign=
"top"><img src=
"clear.gif" width=
"300" height=
"1" alt=
"" /></td>
771 // Select content records per column 772 $contentRecordsPerColumn = $this->getContentRecordsPerColumn('tt_content
', $id, array_values($cList), $showHidden . $showLanguage); 773 // Traverse columns to display top-on-top 774 foreach ($cList as $counter => $key) { 776 $rowArr = $contentRecordsPerColumn[$key]; 777 $this->generateTtContentDataArray($rowArr); 778 $numberOfContentElementsInColumn = count($rowArr); 780 // If it turns out that there are not content elements in the column, then display a big button which links directly to the wizard script: 781 if ($this->doEdit && $this->option_showBigButtons && !(int)$key && $numberOfContentElementsInColumn == 0) { 782 $onClick = 'window.location.href=\
'db_new_content_el.php?id=' .
$id .
'&colPos=' . (int)$key
783 .
'&sys_language_uid=' . $lP .
'&uid_pid=' .
$id .
'&returnUrl=' 785 $theNewButton = $this->getPageLayoutController()->doc->t3Button($onClick, $this->getLanguageService()->getLL('newPageContent
')); 786 $theNewButton = '<img src=
"clear.gif" width=
"1" height=
"5" alt=
"" /><br />
' . $theNewButton; 791 // Traverse any selected elements: 792 foreach ($rowArr as $rKey => $row) { 793 if (is_array($row) && !VersionState::cast($row['t3ver_state
'])->equals(VersionState::DELETE_PLACEHOLDER)) { 795 $editUidList .= $row['uid
'] . ',
'; 796 $isRTE = $RTE && $this->isRTEforField('tt_content
', $row, 'bodytext
'); 797 // Create row output: 801 <td valign=
"top">
' . $this->tt_content_drawHeader($row) . '</td>
803 <td
' . ($row['_ORIG_uid
'] ? ' class=
"ver-element"' : '') . ' valign=
"top">
' 804 . $this->tt_content_drawItem($row, $isRTE) . '</td>
806 // If the element was not the last element, add a divider line: 807 if ($c != $numberOfContentElementsInColumn) { 811 <td colspan=
"3"><img
' 812 . IconUtility::skinImg($this->backPath, 'gfx/stiblet_medium2.gif
', 'width=
"468" height=
"1"') 813 . ' class=
"c-divider" alt=
"" /></td>
817 unset($rowArr[$rKey]); 820 // Add spacer between sections in the vertical list 825 <td colspan=
"3"><br /><br /><br /><br /></td>
828 // Add section header: 829 $newP = $this->newContentElementOnClick($id, $key, $this->tt_contentConfig['sys_language_uid
']); 830 $pasteP = array('colPos
' => $key, 'sys_language_uid
' => $this->tt_contentConfig['sys_language_uid
']); 833 <!-- Column header: -->
836 <td valign=
"top" colspan=
"3">
' . $this->tt_content_drawColHeader( 837 BackendUtility::getProcessedValue('tt_content
', 'colPos
', $key), 838 $this->doEdit && count($rowArr) ? '&edit[tt_content][
' . $editUidList . ']=edit
' . $pageTitleParamForAltDoc : '', 841 ) . $theNewButton . '<br /></td>
843 // Finally, add the content from the records in this column: 846 // Finally, wrap all table rows in one, big table: 848 <table border=
"0" cellpadding=
"0" cellspacing=
"0" width=
"400" class=
"typo3-page-columnsMode">
852 $out .= BackendUtility::cshItem($this->descrTable, 'columns_single
', $GLOBALS['BACK_PATH
']); 854 $out = '<br/><br/>
' . $this->getPageLayoutController()->doc->icons(1) 855 . 'Sorry, you cannot view a single
language in
this localization mode (Default Language Binding is enabled)<br/><br/>
'; 858 // Add the big buttons to page: 859 if ($this->option_showBigButtons) { 861 if (!$this->getPageLayoutController()->current_sys_language) { 862 if ($this->ext_CALC_PERMS & 2) { 863 $bArray[0] = $this->getPageLayoutController()->doc->t3Button( 864 BackendUtility::editOnClick('&edit[pages][
' . $id . ']=edit
', $this->backPath, ''), 865 $this->getLanguageService()->getLL('editPageProperties
') 869 if ($this->doEdit && $this->getBackendUser()->check('tables_modify
', 'pages_language_overlay
')) { 870 list($languageOverlayRecord) = BackendUtility::getRecordsByField( 871 'pages_language_overlay
', 874 'AND sys_language_uid=
' . (int)$this->getPageLayoutController()->current_sys_language 876 $bArray[0] = $this->getPageLayoutController()->doc->t3Button( 877 BackendUtility::editOnClick('&edit[pages_language_overlay][
' . $languageOverlayRecord['uid
'] . ']=edit
', 878 $this->backPath, ''), 879 $this->getLanguageService()->getLL('editPageProperties_curLang
') 883 if ($this->ext_CALC_PERMS & 4 || $this->ext_CALC_PERMS & 2) { 884 $bArray[1] = $this->getPageLayoutController()->doc->t3Button( 885 'window.location.href=\
'' . $this->backPath .
'move_el.php?table=pages&uid=' .
$id 887 $this->getLanguageService()->getLL('move_page
') 890 if ($this->ext_CALC_PERMS & 8) { 891 $bArray[2] = $this->getPageLayoutController()->doc->t3Button( 892 'window.location.href=\
'' . $this->backPath .
'db_new.php?id=' .
$id 894 $this->getLanguageService()->getLL('newPage2
') 897 if ($this->doEdit && $this->ext_function == 1) { 898 $bArray[3] = $this->getPageLayoutController()->doc->t3Button( 899 'window.location.href=\
'db_new_content_el.php?id=' .
$id 902 $this->getLanguageService()->getLL('newPageContent2
') 906 <table border=
"0" cellpadding=
"4" cellspacing=
"0" class=
"typo3-page-buttons">
908 <td>
' . implode('</td>
909 <td>
', $bArray) . '</td>
910 <td>
' . BackendUtility::cshItem($this->descrTable, 'button_panel
', $GLOBALS['BACK_PATH
']) . '</td>
926 public function getBackendLayoutConfiguration() { 927 GeneralUtility::logDeprecatedFunction(); 928 return $this->getBackendLayoutView()->getSelectedBackendLayout($this->id); 931 /********************************** 933 * Generic listing of items 935 **********************************/ 947 public function makeOrdinaryList($table, $id, $fList, $icon = FALSE, $addWhere = '') { 949 $queryParts = $this->makeQueryArray($table, $id, $addWhere); 950 $this->setTotalItems($queryParts); 953 // Make query for records if there were any records found in the count operation 954 if ($this->totalItems) { 955 $result = $this->getDatabase()->exec_SELECT_queryArray($queryParts); 956 // Will return FALSE, if $result is invalid 957 $dbCount = $this->getDatabase()->sql_num_rows($result); 959 // If records were found, render the list 965 $this->fieldArray = GeneralUtility::trimExplode(',
', '__cmds__,
' . $fList . ',__editIconLink__
', TRUE); 967 $theData = $this->headerFields($this->fieldArray, $table, $theData); 969 $localizedTableTitle = $this->getLanguageService()->sL($GLOBALS['TCA
'][$table]['ctrl
']['title
'], TRUE); 970 $out .= '<tr
class=
"t3-row-header">
' . '<td nowrap=
"nowrap" class=
"col-icon"></td>
' 971 . '<td nowrap=
"nowrap" colspan=
"' . (count($theData) - 2) . '"><span
class=
"c-table">
' 972 . $localizedTableTitle . '</span> (
' . $dbCount . ')</td>
' . '<td nowrap=
"nowrap" class=
"col-icon"></td>
' 977 '&edit[' .
$table .
'][' . $this->
id .
']=new',
982 $out .= $this->addelement(1,
'', $theData,
' class="c-headLine"', 15);
987 if (is_array($row)) {
991 $params =
'&edit[' .
$table .
'][' . $row[
'uid'] .
']=edit';
1000 if ($this->doEdit) {
1001 $Nrow[
'__editIconLink__'] =
'<a href="#" onclick="' . htmlspecialchars(
1006 $Nrow[
'__editIconLink__'] = $this->
noEditIcon();
1008 $out .= $this->addelement(1,
'', $Nrow,
'class="db_list_normal"');
1016 Standard list of table "' .
$table .
'" 1018 <table border="0" cellpadding="0" cellspacing="0" class="typo3-dblist"> 1047 foreach ($fieldArr as $fieldName) {
1048 if (
$GLOBALS[
'TCA'][$table][
'columns'][$fieldName]) {
1051 if ($fieldName == $thumbsCol) {
1052 $out[$fieldName] = $this->
thumbCode($row, $table, $fieldName);
1056 BackendUtility::getProcessedValue($table, $fieldName, $row[$fieldName], 0, 0, 0, $row[
'uid']),
1063 $theFields = explode(
';', $fieldName);
1065 foreach ($theFields as $fName2) {
1066 if (
$GLOBALS[
'TCA'][$table][
'columns'][$fName2]) {
1068 $GLOBALS[
'TCA'][$table][
'columns'][$fName2][
'label'],
1071 BackendUtility::getProcessedValue($table, $fName2, $row[$fName2], 0, 0, 0, $row[
'uid']),
1078 if (!$out[$fieldName]) {
1079 $out[$fieldName] =
' ';
1100 foreach ($fieldArr as $fieldName) {
1102 $out[$fieldName] = $ll ? $ll :
' ';
1118 $columns = array_map(
'intval', $columns);
1119 $contentRecordsPerColumn = array_fill_keys($columns, array());
1121 $queryParts = $this->
makeQueryArray(
'tt_content',
$id,
'AND colPos IN (' . implode(
',', $columns) .
')' . $additionalWhereClause);
1126 foreach ($rowArr as $record) {
1127 $columnValue = $record[
'colPos'];
1128 $contentRecordsPerColumn[$columnValue][] = $record;
1131 return $contentRecordsPerColumn;
1153 $res = $this->
getDatabase()->exec_SELECTquery(
'*',
'pages',
'pid=' . (
int)$pid . $qWhere,
'',
'sorting');
1156 while ($row = $this->
getDatabase()->sql_fetch_assoc($res)) {
1158 if (is_array($row)) {
1162 'gfx/ol/join' . ($rc == $c ?
'bottom' :
'') .
'.gif',
1163 'width="18" height="16"' 1169 'gfx/ol/' . ($rc == $c ?
'blank.gif' :
'line.gif'),
1170 'width="18" height="16"' 1172 $theRows = $this->
pages_getTree($theRows, $row[
'uid'], $qWhere, $treeIcons . $spaceOutIcons, $row[
'php_tree_stop'] ? 0 : $depth);
1176 $count = $this->
getDatabase()->exec_SELECTcountRows(
'uid',
'pages',
'pid=' . (
int)$pid . $qWhere);
1178 $this->plusPages[$pid] = $count;
1194 $theIcon = $this->
getIcon(
'pages', $row);
1197 foreach ($fieldArr as $field) {
1200 $red = $this->plusPages[$row[
'uid']] ?
'<font color="red"><strong>+ </strong></font>' :
'';
1201 $pTitle = htmlspecialchars(BackendUtility::getProcessedValue(
'pages', $field, $row[$field], 20));
1203 $pTitle =
'<a href="' 1204 . htmlspecialchars($this->script . ((strpos($this->script,
'?') !== FALSE) ?
'&' :
'?')
1205 .
'id=' . $row[
'uid']) .
'">' . $pTitle .
'</a>';
1207 $theData[$field] = $row[
'treeIcons'] . $theIcon . $red . $pTitle .
' ';
1209 case 'php_tree_stop':
1212 $theData[$field] = $row[$field] ?
' <strong>x</strong>' :
' ';
1216 $params =
'&edit[pages][' . $row[
'uid'] .
']=edit';
1217 $eI =
'<a href="#" onclick="' 1224 $theData[$field] =
'<span align="right">' . $row[
'uid'] . $eI .
'</span>';
1227 if (substr($field, 0, 6) ==
'table_') {
1228 $f2 = substr($field, 6);
1231 $theData[$field] =
' ' . ($c ? $c :
'');
1234 $theData[$field] =
' ' 1235 . htmlspecialchars(BackendUtility::getProcessedValue(
'pages', $field, $row[$field]));
1239 $this->addElement_tdParams[
'title'] = $row[
'_CSSCLASS'] ?
' class="' . $row[
'_CSSCLASS'] .
'"' :
'';
1240 return $this->addelement(1,
'', $theData);
1259 $iconsArr = array();
1261 if ($this->tt_contentConfig[
'showCommands']) {
1264 $iconsArr[
'edit'] =
'<a href="#" onclick="' 1270 $elFromTable = $this->clipboard->elFromTable(
'tt_content');
1271 if (count($elFromTable)) {
1272 $iconsArr[
'paste'] =
'<a href="' 1273 . htmlspecialchars($this->clipboard->pasteUrl(
'tt_content', $this->id, TRUE, $pasteParams))
1274 .
'" onclick="' . htmlspecialchars((
'return ' 1275 . $this->clipboard->confirmMsg(
'pages', $this->pageRecord,
'into', $elFromTable, $colName)))
1282 if (count($iconsArr)) {
1283 $icons =
'<div class="t3-page-colHeader-icons">' . implode(
'', $iconsArr) .
'</div>';
1286 $out =
'<div class="t3-page-colHeader t3-row-header"> 1288 <div class="t3-page-colHeader-label">' . htmlspecialchars($colName) .
'</div> 1303 $this->
getProcessedValue(
'tt_content',
'starttime,endtime,fe_group,spaceBefore,spaceAfter', $row, $info);
1306 $content =
'<div class="t3-page-ce-info"> 1307 ' . implode(
'<br />', $info) .
' 1311 if (!empty($content)) {
1312 $content =
'<div class="t3-page-ce-footer">' . $content .
'</div>';
1328 public function tt_content_drawHeader($row, $space = 0, $disableMoveAndNewButtons = FALSE, $langMode = FALSE, $dragDropEnabled = FALSE) {
1331 if ($this->tt_contentConfig[
'showInfo'] && $this->
getBackendUser()->recordEditAccessInternals(
'tt_content', $row)) {
1333 if ($this->tt_contentConfig[
'showCommands'] && $this->doEdit) {
1335 $params =
'&edit[tt_content][' . $this->tt_contentData[
'nextThree'][$row[
'uid']] .
']=edit';
1340 )) .
'" title="' . htmlspecialchars($this->nextThree > 1
1345 $hiddenField =
$GLOBALS[
'TCA'][
'tt_content'][
'ctrl'][
'enablecolumns'][
'disabled'];
1347 $hiddenField &&
$GLOBALS[
'TCA'][
'tt_content'][
'columns'][$hiddenField]
1348 && (!
$GLOBALS[
'TCA'][
'tt_content'][
'columns'][$hiddenField][
'exclude']
1349 || $this->
getBackendUser()->check(
'non_exclude_fields',
'tt_content:' . $hiddenField))
1351 if ($row[$hiddenField]) {
1358 $params =
'&data[tt_content][' . ($row[
'_ORIG_uid'] ? $row[
'_ORIG_uid'] : $row[
'uid'])
1359 .
'][' . $hiddenField .
']=' . $value;
1365 $params =
'&cmd[tt_content][' . $row[
'uid'] .
'][delete]=1';
1368 . $this->
getLanguageService()->sL(
'LLL:EXT:lang/locallang_core.xlf:labels.translationsOfRecord')))
1371 .
'" onclick="' . htmlspecialchars((
'return confirm(' . $confirm .
');')) .
'" title="' 1374 if (!$disableMoveAndNewButtons) {
1375 $moveButtonContent =
'';
1376 $displayMoveButtons = FALSE;
1378 if ($this->tt_contentData[
'prev'][$row[
'uid']]) {
1379 $params =
'&cmd[tt_content][' . $row[
'uid'] .
'][move]=' . $this->tt_contentData[
'prev'][$row[
'uid']];
1380 $moveButtonContent .=
'<a href="' 1384 if (!$dragDropEnabled) {
1385 $displayMoveButtons = TRUE;
1391 if ($this->tt_contentData[
'next'][$row[
'uid']]) {
1392 $params =
'&cmd[tt_content][' . $row[
'uid'] .
'][move]= ' . $this->tt_contentData[
'next'][$row[
'uid']];
1393 $moveButtonContent .=
'<a href="' 1397 if (!$dragDropEnabled) {
1398 $displayMoveButtons = TRUE;
1403 if ($displayMoveButtons) {
1404 $out .=
'<span class="t3-page-ce-icons-move">' . $moveButtonContent .
'</span>';
1409 $additionalIcons = array();
1410 $additionalIcons[] = $this->
getIcon(
'tt_content', $row) .
' ';
1411 $additionalIcons[] = $langMode ? $this->
languageFlag($row[
'sys_language_uid'], FALSE) :
'';
1415 .
');return false;" title="' . htmlspecialchars($lockInfo[
'msg']) .
'">' 1419 if (is_array(
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'GLOBAL'][
'recStatInfoHooks'])) {
1420 $_params = array(
'tt_content', $row[
'uid'], &$row);
1421 foreach (
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'GLOBAL'][
'recStatInfoHooks'] as $_funcRef) {
1427 return '<h4 class="t3-page-ce-header"> 1428 <div class="t3-row-header"> 1429 <span class="ce-icons-left">' . implode(
'', $additionalIcons) .
'</span> 1430 <span class="ce-icons"> 1434 <div class="t3-page-ce-body">';
1450 if ($row[
'header']) {
1452 $this->
getProcessedValue(
'tt_content',
'header_position,header_layout,header_link', $row, $infoArr);
1453 $hiddenHeaderNote =
'';
1455 if ($row[
'header_layout'] == 100) {
1456 $hiddenHeaderNote =
' <em>[' . $this->
getLanguageService()->sL(
'LLL:EXT:lang/locallang_core.xlf:labels.hidden', TRUE) .
']</em>';
1458 $outHeader = $row[
'date']
1459 ? htmlspecialchars($this->itemLabels[
'date'] .
' ' .
BackendUtility::date($row[
'date'])) .
'<br />' 1462 . $hiddenHeaderNote .
'</strong><br />';
1468 $drawItemHooks = &
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'cms/layout/class.tx_cms_layout.php'][
'tt_content_drawItem'];
1469 if (is_array($drawItemHooks)) {
1470 foreach ($drawItemHooks as $hookClass) {
1473 throw new \UnexpectedValueException(
'$hookObject must implement interface TYPO3\\CMS\\Backend\\View\\PageLayoutViewDrawItemHookInterface', 1218547409);
1475 $hookObject->preProcess($this, $drawItem, $outHeader, $out, $row);
1480 switch ($row[
'CType']) {
1482 if ($row[
'subheader']) {
1491 if ($row[
'CType'] ==
'text' || $row[
'CType'] ==
'textpic') {
1492 if ($row[
'bodytext']) {
1496 if ($row[
'CType'] ==
'textpic' || $row[
'CType'] ==
'image') {
1497 if ($row[
'image']) {
1498 $out .= $this->
thumbCode($row,
'tt_content',
'image') .
'<br />';
1499 $fileReferences = BackendUtility::resolveFileReferences(
'tt_content',
'image', $row);
1500 if (!empty($fileReferences)) {
1501 $linkedContent =
'';
1502 foreach ($fileReferences as $fileReference) {
1503 $linkedContent .= htmlspecialchars($fileReference->getDescription()) .
'<br />';
1506 unset($linkedContent);
1516 if ($row[
'bodytext']) {
1521 if ($row[
'media']) {
1522 $out .= $this->
thumbCode($row,
'tt_content',
'media') .
'<br />';
1526 if ($row[
'multimedia']) {
1527 $out .= $this->
renderText($row[
'multimedia']) .
'<br />';
1528 $out .= $this->
renderText($row[
'parameters']) .
'<br />';
1532 if ($row[
'pages']) {
1537 if (!empty($row[
'records'])) {
1538 $shortcutContent = array();
1539 $recordList = explode(
',', $row[
'records']);
1540 foreach ($recordList as $recordIdentifier) {
1542 $tableName = empty($split[0]) ?
'tt_content' : $split[0];
1543 $shortcutRecord = BackendUtility::getRecord($tableName, $split[1]);
1544 if (is_array($shortcutRecord)) {
1547 $shortcutRecord[
'uid'], 1,
'',
'+copy,info,edit,view', TRUE);
1548 $shortcutContent[] =
'<a href="#" onclick="' . htmlspecialchars($onClick) .
'">' . $icon .
'</a>' 1552 $out .= implode(
'<br />', $shortcutContent) .
'<br />';
1558 if (is_array(
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'cms/layout/class.tx_cms_layout.php'][
'list_type_Info'][$row[
'list_type']])) {
1559 $hookArr =
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'cms/layout/class.tx_cms_layout.php'][
'list_type_Info'][$row[
'list_type']];
1560 } elseif (is_array(
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'cms/layout/class.tx_cms_layout.php'][
'list_type_Info'][
'_DEFAULT'])) {
1561 $hookArr =
$GLOBALS[
'TYPO3_CONF_VARS'][
'SC_OPTIONS'][
'cms/layout/class.tx_cms_layout.php'][
'list_type_Info'][
'_DEFAULT'];
1563 if (count($hookArr) > 0) {
1564 $_params = array(
'pObj' => &$this,
'row' => $row,
'infoArr' => $infoArr);
1565 foreach ($hookArr as $_funcRef) {
1569 if ((
string)$hookOut !==
'') {
1571 } elseif (!empty($row[
'list_type'])) {
1573 if (!empty($label)) {
1574 $out .=
'<strong>' . $this->
getLanguageService()->sL($label, TRUE) .
'</strong><br />';
1576 $message = sprintf($this->
getLanguageService()->sL(
'LLL:EXT:lang/locallang_core.xlf:labels.noMatchingValue'), $row[
'list_type']);
1578 'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
1579 htmlspecialchars($message),
1584 } elseif (!empty($row[
'select_key'])) {
1586 .
' ' . htmlspecialchars($row[
'select_key']) .
'<br />';
1588 $out .=
'<strong>' . $this->
getLanguageService()->getLL(
'noPluginSelected') .
'</strong>';
1597 .
' ' . htmlspecialchars($row[
'select_key']) .
'<br />';
1602 $contentType = $this->CType_labels[$row[
'CType']];
1604 if (isset($contentType)) {
1605 $out .=
'<strong>' . htmlspecialchars($contentType) .
'</strong><br />';
1606 if ($row[
'bodytext']) {
1609 if ($row[
'image']) {
1610 $out .= $this->
thumbCode($row,
'tt_content',
'image') .
'<br />';
1614 $this->
getLanguageService()->sL(
'LLL:EXT:lang/locallang_core.xlf:labels.noMatchingValue'),
1618 'TYPO3\\CMS\\Core\\Messaging\\FlashMessage',
1619 htmlspecialchars($message),
1628 <span class="exampleContent">' . $out .
'</span>';
1630 $out = $outHeader . $out;
1655 if ($lP && count($defLanguageCount)) {
1657 $queryParts = $this->
makeQueryArray(
'tt_content',
$id,
'AND sys_language_uid=' . (
int)$lP
1658 .
' AND l18n_parent IN (' . implode(
',', $defLanguageCount) .
')');
1661 $defLanguageCount = array_flip($defLanguageCount);
1664 foreach ($rowArr as $row) {
1665 unset($defLanguageCount[$row[
'l18n_parent']]);
1668 $defLanguageCount = array_keys($defLanguageCount);
1670 return $defLanguageCount;
1682 if (!$this->doEdit || count($defLanguageCount) === 0 || !$lP) {
1686 foreach ($defLanguageCount as $uidVal) {
1687 $params .=
'&cmd[tt_content][' . $uidVal .
'][localize]=' . $lP;
1690 $onClick =
'window.location.href=\'' . $this->
getPageLayoutController()->doc->issueCommand($params) .
'\';
return false;
'; 1691 $theNewButton = '<div
class=
"t3-page-lang-copyce">
' . 1692 $this->getPageLayoutController()->doc->t3Button( 1694 $this->getLanguageService()->getLL('newPageContent_copyForLang
') . ' [
' . count($defLanguageCount) . ']
' 1696 return $theNewButton; 1709 public function newContentElementOnClick($id, $colPos, $sys_language) { 1710 if ($this->option_newWizard) { 1711 $onClick = 'window.location.href=\
'db_new_content_el.php?id=' .
$id .
'&colPos=' . $colPos
1712 .
'&sys_language_uid=' . $sys_language .
'&uid_pid=' .
$id 1715 $onClick = BackendUtility::editOnClick('&edit[tt_content][
' . $id . ']=
new&defVals[tt_content][colPos]=
' 1716 . $colPos . '&defVals[tt_content][sys_language_uid]=
' . $sys_language, $this->backPath); 1731 public function linkEditContent($str, $row) { 1734 if ($this->doEdit && $this->getBackendUser()->recordEditAccessInternals('tt_content
', $row)) { 1735 // Setting onclick action for content link: 1736 $onClick = BackendUtility::editOnClick('&edit[tt_content][
' . $row['uid
'] . ']=edit
', $this->backPath); 1739 return $onClick ? '<a href=
"#" onclick=
"' . htmlspecialchars($onClick) 1740 . '" title=
"' . $this->getLanguageService()->getLL('edit', TRUE) . '">
' . $str . '</a>
' . $addButton : $str; 1750 public function linkRTEbutton($row) { 1752 $params['table
'] = 'tt_content
'; 1753 $params['uid
'] = $row['uid
']; 1754 $params['pid
'] = $row['pid
']; 1755 $params['field
'] = 'bodytext
'; 1756 $params['returnUrl
'] = GeneralUtility::linkThisScript(); 1757 $RTEonClick = 'window.location.href=
' . GeneralUtility::quoteJSvalue(BackendUtility::getModuleUrl('wizard_rte
', array('P
' => $params))) . ';
return false;
'; 1758 $addButton = $this->option_showBigButtons && $this->doEdit 1759 ? $this->getPageLayoutController()->doc->t3Button($RTEonClick, $this->getLanguageService()->getLL('editInRTE
')) 1774 public function languageSelector($id) { 1775 if ($this->getBackendUser()->check('tables_modify
', 'pages_language_overlay
')) { 1776 // First, select all 1777 $res = $this->getPageLayoutController()->exec_languageQuery(0); 1778 $langSelItems = array(); 1779 $langSelItems[0] = ' 1780 <option value=
"0"></option>
'; 1781 while ($row = $this->getDatabase()->sql_fetch_assoc($res)) { 1782 if ($this->getBackendUser()->checkLanguageAccess($row['uid
'])) { 1783 $langSelItems[$row['uid
']] = ' 1784 <option value=
"' . $row['uid'] . '">
' . htmlspecialchars($row['title
']) . '</option>
'; 1787 // Then, subtract the languages which are already on the page: 1788 $res = $this->getPageLayoutController()->exec_languageQuery($id); 1789 while ($row = $this->getDatabase()->sql_fetch_assoc($res)) { 1790 unset($langSelItems[$row['uid
']]); 1792 // Remove disallowed languages 1793 if (count($langSelItems) > 1 1794 && !$this->getBackendUser()->user['admin
'] 1795 && strlen($this->getBackendUser()->groupData['allowed_languages
']) 1797 $allowed_languages = array_flip(explode(',
', $this->getBackendUser()->groupData['allowed_languages
'])); 1798 if (count($allowed_languages)) { 1799 foreach ($langSelItems as $key => $value) { 1800 if (!isset($allowed_languages[$key]) && $key != 0) { 1801 unset($langSelItems[$key]); 1806 // Remove disabled languages 1807 $modSharedTSconfig = BackendUtility::getModTSconfig($id, 'mod.SHARED
'); 1808 $disableLanguages = isset($modSharedTSconfig['properties
']['disableLanguages
']) 1809 ? GeneralUtility::trimExplode(',
', $modSharedTSconfig['properties
']['disableLanguages
'], TRUE) 1811 if (count($langSelItems) && count($disableLanguages)) { 1812 foreach ($disableLanguages as $language) { 1813 if ($language != 0 && isset($langSelItems[$language])) { 1814 unset($langSelItems[$language]); 1818 // If any languages are left, make selector: 1819 if (count($langSelItems) > 1) { 1820 $onChangeContent = 'window.location.href=\
'' . $this->backPath .
'alt_doc.php?&edit[pages_language_overlay][' 1821 .
$id .
']=new&overrideVals[pages_language_overlay][doktype]=' . (int)$this->pageRecord[
'doktype']
1822 .
'&overrideVals[pages_language_overlay][sys_language_uid]=\'+this.options[this.selectedIndex].value+\'&returnUrl=' 1825 .
': <select name="createNewLanguage" onchange="' . htmlspecialchars($onChangeContent) .
'"> 1826 ' . implode(
'', $langSelItems) .
' 1827 </select><br /><br />';
1876 $this->clipboard->initializeClipboard();
1879 $this->clipboard->lockToNormal();
1882 $this->clipboard->cleanCurrent();
1885 $this->clipboard->endClipboard();
1895 if (empty($this->tt_contentData)) {
1896 $this->tt_contentData = array(
1897 'nextThree' => array(),
1902 foreach ($rowArray as $key => $value) {
1905 if (isset($rowArray[$key - $i])
1906 && !
GeneralUtility::inList($this->tt_contentData[
'nextThree'][$rowArray[$key - $i][
'uid']], $value[
'uid'])
1908 $this->tt_contentData[
'nextThree'][$rowArray[$key - $i][
'uid']] .= $value[
'uid'] .
',';
1913 if (isset($rowArray[$key - 1])) {
1914 if (isset($rowArray[$key - 2])) {
1915 $this->tt_contentData[
'prev'][$value[
'uid']] = -$rowArray[$key - 2][
'uid'];
1917 $this->tt_contentData[
'prev'][$value[
'uid']] = $value[
'pid'];
1919 $this->tt_contentData[
'next'][$rowArray[$key - 1][
'uid']] = -$value[
'uid'];
1936 $count = $this->
getDatabase()->exec_SELECTcountRows(
'uid', $table, $where);
1949 $input = strip_tags($input);
1951 return nl2br(htmlspecialchars(trim($input), ENT_QUOTES,
'UTF-8', FALSE));
1987 $fieldArr = explode(
',', $fieldList);
1989 foreach ($fieldArr as $field) {
1991 $info[] =
'<strong>' . htmlspecialchars($this->itemLabels[$field]) .
'</strong> ' 1992 . htmlspecialchars(BackendUtility::getProcessedValue(
$table, $field, $row[$field]));
2007 return $enableCols[
'disabled'] && $row[$enableCols[
'disabled']]
2008 || $enableCols[
'starttime'] && $row[$enableCols[
'starttime']] >
$GLOBALS[
'EXEC_TIME']
2009 || $enableCols[
'endtime'] && $row[$enableCols[
'endtime']] && $row[$enableCols[
'endtime']] <
$GLOBALS[
'EXEC_TIME'];
2026 $array = preg_split(
'/[ ' . LF .
']/', $content);
2027 foreach ($array as $val) {
2028 if (strlen($val) > $max) {
2029 $content = str_replace($val, substr(chunk_split($val, $max, $char), 0, -1), $content);
2046 'status-edit-read-only',
2060 $tableNames = array_flip(array_keys(
$GLOBALS[
'TCA']));
2062 unset($tableNames[
'pages']);
2063 unset($tableNames[
'static_template']);
2064 unset($tableNames[
'sys_filemounts']);
2065 unset($tableNames[
'sys_action']);
2066 unset($tableNames[
'sys_workflows']);
2067 unset($tableNames[
'be_users']);
2068 unset($tableNames[
'be_groups']);
2069 $allowedTableNames = array();
2071 if (is_array($tableNames)) {
2072 foreach ($tableNames as $k => $v) {
2074 $allowedTableNames[
'table_' . $k] = $k;
2078 return $allowedTableNames;
2093 if (!count($specConf)) {
2097 if (isset($specConf[
'richtext']) && (!$p[
'flag'] || !$row[$p[
'flag']])) {
2101 if ($thePidValue >= 0) {
2102 if (!isset($this->rteSetup[$tscPID])) {
2107 if (!$thisConfig[
'disabled']) {
2131 if (is_array($types_fieldConfig)) {
2132 foreach ($types_fieldConfig as $vConf) {
2133 if ($vConf[
'field'] == $field) {
2134 return $vConf[
'spec'];
2158 $this->activeTables = array();
2159 $theTables = array(
'tt_content');
2161 if (is_array($this->externalTables)) {
2162 $theTables = array_unique(array_merge($theTables, array_keys($this->externalTables)));
2166 foreach ($theTables as $tName) {
2169 && (isset($this->externalTables[$tName])
2171 || \
TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded($tName)
2175 $c = $this->
getDatabase()->exec_SELECTcountRows(
'uid', $tName,
'pid=' . (
int)
$id 2199 Menu of tables on the page (table menu) 2201 <table border="0" cellpadding="0" cellspacing="0" id="typo3-page-tblMenu"> 2214 'TYPO3\\CMS\\Backend\\View\\BackendLayoutView' tt_content_drawFooter(array $row)
pages_getTree($theRows, $pid, $qWhere, $treeIcons, $depth)
static translationCount($table, $ref, $msg='')
getSelectedBackendLayoutUid($id)
wordWrapper($content, $max=50, $char=' -')
static skinImg($backPath, $src, $wHattribs='', $outputMode=0)
getResult($result, $table='tt_content')
static getRecordWSOL($table, $uid, $fields=' *', $where='', $useDeleteClause=TRUE, $unsetMovePointers=FALSE)
generateTtContentDataArray(array $rowArray)
static editOnClick($params, $backPath='', $requestUri='')
static getItemLabel($table, $col, $printAllWrap='')
getNonTranslatedTTcontentUids($defLanguageCount, $id, $lP)
static getTCAtypeValue($table, $row)
getProcessedValue($table, $fieldList, array $row, array &$info)
languageFlag($sys_language_uid, $addAsAdditionalText=TRUE)
tt_content_drawHeader($row, $space=0, $disableMoveAndNewButtons=FALSE, $langMode=FALSE, $dragDropEnabled=FALSE)
static quoteJSvalue($value)
static workspaceOL($table, &$row, $wsid=-99, $unsetMovePointers=FALSE)
getSpecConfForField($table, $row, $field)
static intExplode($delimiter, $string, $removeEmptyValues=FALSE, $limit=0)
dataFields($fieldArr, $table, $row, $out=array())
static cshItem($table, $field, $BACK_PATH, $wrap='', $onlyIconMode=FALSE, $styleAttrib='')
static getIndpEnv($getEnvName)
static getUserObj($classRef, $checkPrefix='', $silent=FALSE)
getContentRecordsPerColumn($table, $id, array $columns, $additionalWhereClause='')
isRTEforField($table, $row, $field)
static logDeprecatedFunction()
newContentElementOnClick($id, $colPos, $sys_language)
static makeInstance($className)
makeQueryArray($table, $id, $addWhere='', $fieldList=' *')
static trimExplode($delim, $string, $removeEmptyValues=FALSE, $limit=0)
newLanguageButton($defLanguageCount, $lP)
static callUserFunction($funcName, &$params, &$ref, $checkPrefix='', $errorMode=0)
getExternalTables($id, $table)
static getTSCpid($table, $uid, $pid)
tt_content_drawItem($row, $isRTE=FALSE)
static getRecordTitle($table, $row, $prep=FALSE, $forceResult=TRUE)
static getSpriteIconForRecord($table, array $row, array $options=array())
if(!defined('TYPO3_MODE')) if(TYPO3_MODE=='BE' &&!(TYPO3_REQUESTTYPE &TYPO3_REQUESTTYPE_INSTALL)) $icons
getPageLayoutController()
numberOfRecords($table, $pid)
noEditIcon($label='noEditItems')
if($list_of_literals) if(!empty($literals)) if(!empty($literals)) $result
Analyse literals to prepend the N char to them if their contents aren't numeric.
static versioningPlaceholderClause($table)
pages_drawItem($row, $fieldArr)
static isRecordLocked($table, $uid)
static getSpriteIcon($iconName, array $options=array(), array $overlays=array())
static getTCAtypes($table, $rec, $useFieldNameAsKey=0)
static RTEsetup($RTEprop, $table, $field, $type='')
tt_content_drawColHeader($colName, $editParams, $newParams, array $pasteParams=NULL)
static getSpecConfParametersFromArray($pArr)
linkEditContent($str, $row)
static getRecordIconAltText($row, $table='pages')
static fixed_lgd_cs($string, $chars, $appendString='...')
static fixVersioningPid($table, &$rr, $ignoreWorkspaceMatch=FALSE)
static getLabelFromItemListMerged($pageId, $table, $column, $key)
if(!defined('TYPO3_MODE')) $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_userauth.php']['logoff_pre_processing'][]
static inList($list, $item)
thumbCode($row, $table, $field)
static getPagesTSconfig($id, $rootLine=NULL, $returnPartArray=FALSE)
static splitTable_Uid($str)
makeOrdinaryList($table, $id, $fList, $icon=FALSE, $addWhere='')
static BEenableFields($table, $inv=0)
static deleteClause($table, $tableAlias='')
static getLabelFromItemlist($table, $col, $key)
headerFields($fieldArr, $table, $out=array())