TYPO3 CMS  TYPO3_6-2
db_layout.php
Go to the documentation of this file.
1 <?php
22 unset($MCONF);
23 require __DIR__ . '/conf.php';
24 require $BACK_PATH . 'init.php';
25 $LANG->includeLLFile('EXT:cms/layout/locallang.xlf');
26 
27 $BE_USER->modAccess($MCONF, 1);
28 // Will open up records locked by current user. It's assumed that the locking should end if this script is hit.
30 // Exits if 'cms' extension is not loaded:
38 
43 
47  public $l_insertNewRecordHere = 'newContentElement';
48 
57  public function wrapRecordTitle($str, $row) {
58  $aOnClick = 'jumpToUrl(' . \TYPO3\CMS\Core\Utility\GeneralUtility::quoteJSvalue($GLOBALS['SOBE']->local_linkThisScript(array('edit_record' => ('tt_content:' . $row['uid'])))) . ');return false;';
59  return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $str . '</a>';
60  }
61 
71  public function wrapColumnHeader($str, $vv) {
72  $aOnClick = 'jumpToUrl(' . \TYPO3\CMS\Core\Utility\GeneralUtility::quoteJSvalue($GLOBALS['SOBE']->local_linkThisScript(array('edit_record' => ('_EDIT_COL:' . $vv)))) . ');return false;';
73  return '<a href="#" onclick="' . htmlspecialchars($aOnClick) . '">' . $str . '</a>';
74  }
75 
87  public function onClickInsertRecord($row, $vv, $moveUid, $pid, $sys_lang = 0) {
88  if (is_array($row)) {
89  $location = $GLOBALS['SOBE']->local_linkThisScript(array('edit_record' => 'tt_content:new/-' . $row['uid'] . '/' . $row['colPos']));
90  } else {
91  $location = $GLOBALS['SOBE']->local_linkThisScript(array('edit_record' => 'tt_content:new/' . $pid . '/' . $vv));
92  }
93  return 'jumpToUrl(' . \TYPO3\CMS\Core\Utility\GeneralUtility::quoteJSvalue($location) . ');return false;';
94  }
95 
104  public function wrapRecordHeader($str, $row) {
105  if ($row['uid'] == $this->moveUid) {
106  return '<img' . \TYPO3\CMS\Backend\Utility\IconUtility::skinImg($GLOBALS['BACK_PATH'], 'gfx/content_client.gif', 'width="7" height="10"') . ' alt="" />' . $str;
107  } else {
108  return $str;
109  }
110  }
111 
112 }
113 
114 /*
115  * @deprecated since 6.0, the classname SC_db_layout and this file is obsolete
116  * and will be removed with 6.2. The class was renamed and is now located at:
117  * typo3/sysext/backend/Classes/Controller/PageLayoutController.php
118  */
119 require_once \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath('backend') . 'Classes/Controller/PageLayoutController.php';
120 // Make instance:
121 $SOBE = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Controller\\PageLayoutController');
122 $SOBE->init();
123 // Include files?
124 foreach ($SOBE->include_once as $INC_FILE) {
125  include_once $INC_FILE;
126 }
127 $SOBE->clearCache();
128 $SOBE->main();
129 $SOBE->printContent();
static skinImg($backPath, $src, $wHattribs='', $outputMode=0)
$MCONF['navFrameScript']
Definition: conf.php:4
wrapRecordTitle($str, $row)
Definition: db_layout.php:57
static lockRecords($table='', $uid=0, $pid=0)
$BACK_PATH
Definition: conf.php:3
wrapRecordHeader($str, $row)
Definition: db_layout.php:104
onClickInsertRecord($row, $vv, $moveUid, $pid, $sys_lang=0)
Definition: db_layout.php:87
$dontPrintPageInsertIcons
Definition: db_layout.php:42
$l_insertNewRecordHere
Definition: db_layout.php:47
wrapColumnHeader($str, $vv)
Definition: db_layout.php:71
if(!defined('TYPO3_MODE')) $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_userauth.php']['logoff_pre_processing'][]
$SOBE
Definition: db_layout.php:121
$BE_USER
Definition: index_ts.php:114