本文整理汇总了PHP中TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig方法的典型用法代码示例。如果您正苦于以下问题:PHP BackendUtility::getModTSconfig方法的具体用法?PHP BackendUtility::getModTSconfig怎么用?PHP BackendUtility::getModTSconfig使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TYPO3\CMS\Backend\Utility\BackendUtility
的用法示例。
在下文中一共展示了BackendUtility::getModTSconfig方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: init
/**
* First initialization of global variables
*
* @return void
*/
function init()
{
$this->MCONF = $GLOBALS['MCONF'];
parent::init();
// initialize IconFactory
$this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
// get TS Params
$temp = BackendUtility::getModTSconfig($this->id, 'mod.web_modules.dmail');
if (!is_array($temp['properties'])) {
$temp['properties'] = array();
}
$this->params = $temp['properties'];
$this->implodedParams = DirectMailUtility::implodeTSParams($this->params);
$this->MOD_MENU['dmail_mode'] = BackendUtility::unsetMenuItems($this->params, $this->MOD_MENU['dmail_mode'], 'menu.dmail_mode');
// initialize the page selector
$this->sys_page = GeneralUtility::makeInstance('TYPO3\\CMS\\Frontend\\Page\\PageRepository');
$this->sys_page->init(true);
// initialize backend user language
if ($this->getLanguageService()->lang && ExtensionManagementUtility::isLoaded('static_info_tables')) {
$res = $GLOBALS["TYPO3_DB"]->exec_SELECTquery('sys_language.uid', 'sys_language LEFT JOIN static_languages ON sys_language.static_lang_isocode=static_languages.uid', 'static_languages.lg_typo3=' . $GLOBALS["TYPO3_DB"]->fullQuoteStr($this->getLanguageService()->lang, 'static_languages') . BackendUtility::BEenableFields('sys_language') . BackendUtility::deleteClause('sys_language') . BackendUtility::deleteClause('static_languages'));
while ($row = $GLOBALS["TYPO3_DB"]->sql_fetch_assoc($res)) {
$this->sys_language_uid = $row['uid'];
}
}
// load contextual help
$this->cshTable = '_MOD_' . $this->MCONF['name'];
if ($GLOBALS["BE_USER"]->uc['edit_showFieldHelp']) {
$this->getLanguageService()->loadSingleTableDescription($this->cshTable);
}
}
示例2: getSystemLanguages
/**
* Returns array of system languages
*
* Since TYPO3 4.5 the flagIcon is not returned as a filename in "gfx/flags/*" anymore,
* but as a string <flags-xx>. The calling party should call
* t3lib_iconWorks::getSpriteIcon(<flags-xx>) to get an HTML which will represent
* the flag of this language.
*
* @param integer $page_id Page id (only used to get TSconfig configuration setting flag and label for default language)
* @param string $backPath Backpath for flags
* @return array Array with languages (title, uid, flagIcon)
* @todo Define visibility
*/
public function getSystemLanguages($page_id = 0, $backPath = '')
{
$modSharedTSconfig = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($page_id, 'mod.SHARED');
$languageIconTitles = array();
// fallback "old iconstyles"
if (preg_match('/\\.gif$/', $modSharedTSconfig['properties']['defaultLanguageFlag'])) {
$modSharedTSconfig['properties']['defaultLanguageFlag'] = str_replace('.gif', '', $modSharedTSconfig['properties']['defaultLanguageFlag']);
}
$languageIconTitles[0] = array('uid' => 0, 'title' => strlen($modSharedTSconfig['properties']['defaultLanguageLabel']) ? $modSharedTSconfig['properties']['defaultLanguageLabel'] . ' (' . $GLOBALS['LANG']->sl('LLL:EXT:lang/locallang_mod_web_list.xml:defaultLanguage') . ')' : $GLOBALS['LANG']->sl('LLL:EXT:lang/locallang_mod_web_list.xml:defaultLanguage'), 'ISOcode' => 'DEF', 'flagIcon' => strlen($modSharedTSconfig['properties']['defaultLanguageFlag']) ? 'flags-' . $modSharedTSconfig['properties']['defaultLanguageFlag'] : 'empty-empty');
// Set "All" language:
$languageIconTitles[-1] = array('uid' => -1, 'title' => $GLOBALS['LANG']->getLL('multipleLanguages'), 'ISOcode' => 'DEF', 'flagIcon' => 'flags-multiple');
// Find all system languages:
$sys_languages = $GLOBALS['TYPO3_DB']->exec_SELECTgetRows('*', 'sys_language', '');
foreach ($sys_languages as $row) {
$languageIconTitles[$row['uid']] = $row;
if ($row['static_lang_isocode'] && \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::isLoaded('static_info_tables')) {
$staticLangRow = \TYPO3\CMS\Backend\Utility\BackendUtility::getRecord('static_languages', $row['static_lang_isocode'], 'lg_iso_2');
if ($staticLangRow['lg_iso_2']) {
$languageIconTitles[$row['uid']]['ISOcode'] = $staticLangRow['lg_iso_2'];
}
}
if (strlen($row['flag'])) {
$languageIconTitles[$row['uid']]['flagIcon'] = \TYPO3\CMS\Backend\Utility\IconUtility::mapRecordTypeToSpriteIconName('sys_language', $row);
}
}
return $languageIconTitles;
}
示例3: init
/**
* Initializes the Module
* @return void
*/
function init()
{
$id = intval(\TYPO3\CMS\Core\Utility\GeneralUtility::_GP('id'));
$tsconfig = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($id, 'tx_formhandler_mod1');
$this->settings = $tsconfig['properties']['config.'];
parent::init();
}
示例4: init
/**
* Initializing global variables
*
* @return void no return values: first initialisation of global variables
*/
function init()
{
$this->MCONF = $GLOBALS['MCONF'];
parent::init();
$temp = BackendUtility::getModTSconfig($this->id, 'mod.web_modules.dmail');
$this->params = $temp['properties'];
$this->implodedParams = BackendUtility::implodeTSParams($this->params);
if ($this->params['userTable'] && is_array($GLOBALS["TCA"][$this->params['userTable']])) {
$this->userTable = $this->params['userTable'];
$this->allowedTables[] = $this->userTable;
}
$this->MOD_MENU['dmail_mode'] = BackendUtility::unsetMenuItems($this->params, $this->MOD_MENU['dmail_mode'], 'menu.dmail_mode');
// initialize backend user language
if ($GLOBALS["LANG"]->lang && ExtensionManagementUtility::isLoaded('static_info_tables')) {
$res = $GLOBALS["TYPO3_DB"]->exec_SELECTquery('sys_language.uid', 'sys_language LEFT JOIN static_languages ON sys_language.static_lang_isocode=static_languages.uid', 'static_languages.lg_typo3=' . $GLOBALS["TYPO3_DB"]->fullQuoteStr($GLOBALS["LANG"]->lang, 'static_languages') . BackendUtility::BEenableFields('sys_language') . BackendUtility::deleteClause('sys_language') . BackendUtility::deleteClause('static_languages'));
while ($row = $GLOBALS["TYPO3_DB"]->sql_fetch_assoc($res)) {
$this->sys_language_uid = $row['uid'];
}
$GLOBALS["TYPO3_DB"]->sql_free_result($res);
}
// load contextual help
$this->cshTable = '_MOD_' . $this->MCONF['name'];
if ($GLOBALS["BE_USER"]->uc['edit_showFieldHelp']) {
$GLOBALS["LANG"]->loadSingleTableDescription($this->cshTable);
}
}
示例5: main
/**
* Main processing, creating the list of new record tables to select from.
*
* @return void
*/
public function main()
{
// if commerce parameter is missing use default controller
if (!GeneralUtility::_GP('parentCategory')) {
parent::main();
return;
}
// If there was a page - or if the user is admin
// (admins has access to the root) we proceed:
if ($this->pageinfo['uid'] || $this->getBackendUserAuthentication()->isAdmin()) {
// Acquiring TSconfig for this module/current page:
$this->web_list_modTSconfig = BackendUtility::getModTSconfig($this->pageinfo['uid'], 'mod.web_list');
// allow only commerce related tables
$this->allowedNewTables = array('tx_commerce_categories', 'tx_commerce_products');
$this->deniedNewTables = GeneralUtility::trimExplode(',', $this->web_list_modTSconfig['properties']['deniedNewTables'], true);
// Acquiring TSconfig for this module/parent page:
$this->web_list_modTSconfig_pid = BackendUtility::getModTSconfig($this->pageinfo['pid'], 'mod.web_list');
$this->allowedNewTables_pid = GeneralUtility::trimExplode(',', $this->web_list_modTSconfig_pid['properties']['allowedNewTables'], true);
$this->deniedNewTables_pid = GeneralUtility::trimExplode(',', $this->web_list_modTSconfig_pid['properties']['deniedNewTables'], true);
// More init:
if (!$this->showNewRecLink('pages')) {
$this->newPagesInto = 0;
}
if (!$this->showNewRecLink('pages', $this->allowedNewTables_pid, $this->deniedNewTables_pid)) {
$this->newPagesAfter = 0;
}
// Set header-HTML and return_url
if (is_array($this->pageinfo) && $this->pageinfo['uid']) {
$iconImgTag = IconUtility::getSpriteIconForRecord('pages', $this->pageinfo, array('title' => htmlspecialchars($this->pageinfo['_thePath'])));
$title = strip_tags($this->pageinfo[SettingsFactory::getInstance()->getTcaValue('pages.ctrl.label')]);
} else {
$iconImgTag = IconUtility::getSpriteIcon('apps-pagetree-root', array('title' => htmlspecialchars($this->pageinfo['_thePath'])));
$title = $GLOBALS['TYPO3_CONF_VARS']['SYS']['sitename'];
}
$this->code = '<span class="typo3-moduleHeader">' . $this->doc->wrapClickMenuOnIcon($iconImgTag, 'pages', $this->pageinfo['uid']) . htmlspecialchars(GeneralUtility::fixed_lgd_cs($title, 45)) . '</span><br />';
$this->R_URI = $this->returnUrl;
// GENERATE the HTML-output depending on mode (pagesOnly is the page wizard)
// Regular new element:
if (!$this->pagesOnly) {
$this->regularNew();
} elseif ($this->showNewRecLink('pages')) {
// Pages only wizard
$this->pagesOnly();
}
// Add all the content to an output section
$this->content .= $this->doc->section('', $this->code);
// Setting up the buttons and markers for docheader
$docHeaderButtons = $this->getButtons();
$markers['CSH'] = $docHeaderButtons['csh'];
$markers['CONTENT'] = $this->content;
// Build the <body> for the module
$this->content = $this->doc->startPage($this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:db_new.php.pagetitle'));
$this->content .= $this->doc->moduleBody($this->pageinfo, $docHeaderButtons, $markers);
$this->content .= $this->doc->endPage();
$this->content = $this->doc->insertStylesAndJS($this->content);
}
}
示例6: init
/**
*
* Initializes the Module
* @return void
*
*/
function init()
{
global $TBE_STYLES;
$this->id = (int) GeneralUtility::_GP('id');
#$this->modTSconfig = BackendUtility::getModTSconfig($this->id, 'mod.' . $this->MCONF['name']);
$this->modTSconfig = BackendUtility::getModTSconfig($this->id, 'mod.' . $GLOBALS["MCONF"]["name"]);
parent::init();
$TBE_STYLES['stylesheet2'] = ExtensionManagementUtility::extRelPath('mm_forum') . 'mod1/css/style.css';
$this->doc = GeneralUtility::makeInstance('TYPO3\\CMS\\Backend\\Template\\DocumentTemplate');
}
示例7: initializeAction
/**
* Initialize action
*
* @return void
*/
protected function initializeAction()
{
// initialize page/be_user TSconfig settings
$this->modSharedTSconfig = BackendUtility::getModTSconfig($this->id, 'mod.SHARED');
$this->modTSconfig = BackendUtility::getModTSconfig($this->id, 'mod.' . $this->moduleName);
// initialize settings of the module
$this->initializeModParams();
if (!$this->request->hasArgument('action') && $this->modParams['action']) {
$this->request->setArgument('action', $this->modParams['action']);
$this->forward($this->modParams['action']);
}
// get languages
$this->languages = $this->getLanguages();
}
示例8: execute
/**
* Function executed from scheduler.
* Creates a new newsletter record, and sets the scheduled time to "now"
*
* @return bool
*/
public function execute()
{
if ($this->draftUid > 0) {
$this->initializeHookObjects();
$hookParams = array();
$draftRecord = BackendUtility::getRecord('sys_dmail', $this->draftUid);
// get some parameters from tsConfig
$tsConfig = BackendUtility::getModTSconfig($draftRecord['pid'], 'mod.web_modules.dmail');
$defaultParams = $tsConfig['properties'];
// make a real record out of it
unset($draftRecord['uid']);
$draftRecord['tstamp'] = time();
// set the right type (3 => 1, 2 => 0)
$draftRecord['type'] -= 2;
// check if domain record is set
if (TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_CLI && (int) $draftRecord['type'] !== 1 && empty($draftRecord['use_domain'])) {
throw new \Exception('No domain record set!');
}
// Insert the new dmail record into the DB
$GLOBALS['TYPO3_DB']->exec_INSERTquery('sys_dmail', $draftRecord);
$this->dmailUid = $GLOBALS['TYPO3_DB']->sql_insert_id();
// Call a hook after insertion of the cloned dmail record
// This hook can get used to modify fields of the direct mail.
// For example the current date could get appended to the subject.
$hookParams['draftRecord'] =& $draftRecord;
$hookParams['defaultParams'] =& $defaultParams;
$this->callHooks('postInsertClone', $hookParams);
// fetch the cloned record
$mailRecord = BackendUtility::getRecord('sys_dmail', $this->dmailUid);
// fetch mail content
$result = DirectMailUtility::fetchUrlContentsForDirectMailRecord($mailRecord, $defaultParams, TRUE);
if ($result['errors'] !== array()) {
throw new \Exception('Failed to fetch contents: ' . implode(', ', $result['errors']));
}
$mailRecord = BackendUtility::getRecord('sys_dmail', $this->dmailUid);
if ($mailRecord['mailContent'] && $mailRecord['renderedsize'] > 0) {
$updateData = array('scheduled' => time(), 'issent' => 1);
// Call a hook before enqueuing the cloned dmail record into
// the direct mail delivery queue
$hookParams['mailRecord'] =& $mailRecord;
$hookParams['updateData'] =& $updateData;
$this->callHooks('enqueueClonedDmail', $hookParams);
// Update the cloned dmail so it will get sent upon next
// invocation of the mailer engine
$GLOBALS['TYPO3_DB']->exec_UPDATEquery('sys_dmail', 'uid = ' . intval($this->dmailUid), $updateData);
}
}
return true;
}
示例9: menuConfig
/**
* Adds items to the ->MOD_MENU array. Used for the function menu selector.
*
* @return void
*/
public function menuConfig()
{
$this->MOD_MENU = array('mode' => array());
$this->MOD_MENU['mode']['information'] = $this->getLanguageService()->sL('LLL:EXT:taskcenter/Resources/Private/Language/locallang.xlf:task_overview');
$this->MOD_MENU['mode']['tasks'] = $this->getLanguageService()->sL('LLL:EXT:taskcenter/Resources/Private/Language/locallang.xlf:task_tasks');
/* Copied from parent::menuConfig, because parent is hardcoded to menu.function,
* however menu.function is already used for the individual tasks.
* Therefore we use menu.mode here.
*/
// Page/be_user TSconfig settings and blinding of menu-items
$this->modTSconfig = BackendUtility::getModTSconfig($this->id, 'mod.' . $this->moduleName);
$this->MOD_MENU['mode'] = $this->mergeExternalItems($this->MCONF['name'], 'mode', $this->MOD_MENU['mode']);
$this->MOD_MENU['mode'] = BackendUtility::unsetMenuItems($this->modTSconfig['properties'], $this->MOD_MENU['mode'], 'menu.mode');
parent::menuConfig();
}
示例10: init
/**
* First initialization of global variables
*
* @return void
*/
function init()
{
$this->MCONF = $GLOBALS['MCONF'];
parent::init();
// initialize IconFactory
$this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
// get the config from pageTS
$temp = BackendUtility::getModTSconfig($this->id, 'mod.web_modules.dmail');
if (!is_array($temp['properties'])) {
$temp['properties'] = array();
}
$this->params = $temp['properties'];
$this->implodedParams = DirectMailUtility::implodeTSParams($this->params);
if ($this->params['userTable'] && is_array($GLOBALS['TCA'][$this->params['userTable']])) {
$this->userTable = $this->params['userTable'];
$this->allowedTables[] = $this->userTable;
}
// check if the right domain shoud be set
if (!$this->params['use_domain']) {
$rootLine = BackendUtility::BEgetRootLine($this->id);
if ($rootLine) {
$parts = parse_url(GeneralUtility::getIndpEnv('TYPO3_SITE_URL'));
if (BackendUtility::getDomainStartPage($parts['host'], $parts['path'])) {
$temporaryPreUrl = BackendUtility::firstDomainRecord($rootLine);
$domain = BackendUtility::getRecordsByField('sys_domain', 'domainName', $temporaryPreUrl, ' AND hidden=0', '', 'sorting');
if (is_array($domain)) {
reset($domain);
$dom = current($domain);
$this->params['use_domain'] = $dom['uid'];
}
}
}
}
$this->MOD_MENU['dmail_mode'] = BackendUtility::unsetMenuItems($this->params, $this->MOD_MENU['dmail_mode'], 'menu.dmail_mode');
// initialize backend user language
if ($this->getLanguageService()->lang && ExtensionManagementUtility::isLoaded('static_info_tables')) {
$res = $GLOBALS['TYPO3_DB']->exec_SELECTquery('sys_language.uid', 'sys_language LEFT JOIN static_languages ON sys_language.static_lang_isocode=static_languages.uid', 'static_languages.lg_typo3=' . $GLOBALS['TYPO3_DB']->fullQuoteStr($this->getLanguageService()->lang, 'static_languages') . BackendUtility::BEenableFields('sys_language') . BackendUtility::deleteClause('sys_language') . BackendUtility::deleteClause('static_languages'));
while ($row = $GLOBALS['TYPO3_DB']->sql_fetch_assoc($res)) {
$this->sys_language_uid = $row['uid'];
}
$GLOBALS['TYPO3_DB']->sql_free_result($res);
}
// load contextual help
$this->cshTable = '_MOD_' . $this->MCONF['name'];
if ($GLOBALS['BE_USER']->uc['edit_showFieldHelp']) {
$this->getLanguageService()->loadSingleTableDescription($this->cshTable);
}
}
示例11: getWeekStartDay
public function getWeekStartDay($PA)
{
$pageID = $PA['row']['pid'];
$tsConfig = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($pageID, 'options.tx_cal_controller.weekStartDay');
$weekStartDay = strtolower($tsConfig['value']);
switch ($weekStartDay) {
case 'sunday':
$startDay = 'su';
break;
/* If there's any value other than sunday, assume we want Monday */
/* If there's any value other than sunday, assume we want Monday */
default:
$startDay = 'mo';
break;
}
return $startDay;
}
示例12: getColPosListItemsParsed
/**
* Gets the list of available columns for a given page id
*
* @param integer $id
* @return array $tcaItems
*/
public function getColPosListItemsParsed($id)
{
$tsConfig = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($id, 'TCEFORM.tt_content.colPos');
$tcaConfig = $GLOBALS['TCA']['tt_content']['columns']['colPos']['config'];
/** @var $tceForms t3lib_TCEForms */
$tceForms = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('t3lib_TCEForms');
$tcaItems = $tcaConfig['items'];
$tcaItems = $tceForms->addItems($tcaItems, $tsConfig['properties']['addItems.']);
if (isset($tcaConfig['itemsProcFunc']) && $tcaConfig['itemsProcFunc']) {
$tcaItems = $this->addColPosListLayoutItems($id, $tcaItems);
}
foreach (\TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(',', $tsConfig['properties']['removeItems'], 1) as $removeId) {
foreach ($tcaItems as $key => $item) {
if ($item[1] == $removeId) {
unset($tcaItems[$key]);
}
}
}
return $tcaItems;
}
示例13: getCategories
/**
* Returns the list of categories with their ID.
*
* @param array $config Associative array of existing configurations
* @param \TYPO3\CMS\Backend\Form\FormEngine|\TYPO3\CMS\Backend\Form\DataPreprocessor $tceForms TCE forms object
* @param string $sitecode Unique code of the site to retrieve the categories for
* @return array Associative array with existing and new entries
*/
public function getCategories(array $config, $tceForms = null, $sitecode = 'default')
{
if (isset($config['row']) && isset($config['row']['pid'])) {
$pageTSConfig = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($config['row']['pid'], 'tx_aimeos');
if (isset($pageTSConfig['properties']['mshop.']['locale.']['site'])) {
$sitecode = $pageTSConfig['properties']['mshop.']['locale.']['site'];
}
}
try {
$context = Base::getContext(Base::getConfig());
$context->setEditor('flexform');
$localeManager = \MShop_Locale_Manager_Factory::createManager($context);
$context->setLocale($localeManager->bootstrap($sitecode, '', '', false));
$manager = \MShop_Catalog_Manager_Factory::createManager($context);
$item = $manager->getTree(null, array(), \MW_Tree_Manager_Abstract::LEVEL_TREE);
$config['items'] = array_merge($config['items'], $this->getCategoryList($item, 0));
} catch (Exception $e) {
error_log($e->getMessage() . PHP_EOL . $e->getTraceAsString());
}
return $config;
}
示例14: getSystemLanguages
/**
* Returns array of system languages
*
* The property flagIcon returns a string <flags-xx>. The calling party should call
* \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon(<flags-xx>) to get an HTML
* which will represent the flag of this language.
*
* @param int $pageId Page id (used to get TSconfig configuration setting flag and label for default language)
* @return array Array with languages (uid, title, ISOcode, flagIcon)
*/
public function getSystemLanguages($pageId = 0)
{
$modSharedTSconfig = BackendUtility::getModTSconfig($pageId, 'mod.SHARED');
// default language and "all languages" are always present
$languages = array(0 => array('uid' => 0, 'title' => $this->getDefaultLanguageLabel($modSharedTSconfig), 'ISOcode' => 'DEF', 'flagIcon' => $this->getDefaultLanguageFlag($modSharedTSconfig)), -1 => array('uid' => -1, 'title' => $this->getLanguageService()->getLL('multipleLanguages'), 'ISOcode' => 'DEF', 'flagIcon' => 'flags-multiple'));
// add the additional languages from database records
$languageRecords = $this->getDatabaseConnection()->exec_SELECTgetRows('*', 'sys_language', '');
foreach ($languageRecords as $languageRecord) {
$languages[$languageRecord['uid']] = $languageRecord;
if ($languageRecord['static_lang_isocode'] && ExtensionManagementUtility::isLoaded('static_info_tables')) {
$staticLangRow = BackendUtility::getRecord('static_languages', $languageRecord['static_lang_isocode'], 'lg_iso_2');
if ($staticLangRow['lg_iso_2']) {
$languages[$languageRecord['uid']]['ISOcode'] = $staticLangRow['lg_iso_2'];
}
}
if ($languageRecord['flag'] !== '') {
$languages[$languageRecord['uid']]['flagIcon'] = IconUtility::mapRecordTypeToSpriteIconName('sys_language', $languageRecord);
}
}
return $languages;
}
示例15: DB_newWizard
/**
* Adding CM element for Create new wizard (either db_new.php or sysext/cms/layout/db_new_content_el.php or custom wizard)
*
* @param string $table Table name
* @param integer $uid UID for the current record.
* @param array $rec Record.
* @return array Item array, element in $menuItems
* @internal
* @todo Define visibility
*/
public function DB_newWizard($table, $uid, $rec)
{
// If mod.web_list.newContentWiz.overrideWithExtension is set, use that extension's create new content wizard instead:
$tmpTSc = \TYPO3\CMS\Backend\Utility\BackendUtility::getModTSconfig($this->pageinfo['uid'], 'mod.web_list');
$tmpTSc = $tmpTSc['properties']['newContentWiz.']['overrideWithExtension'];
$newContentWizScriptPath = \TYPO3\CMS\Core\Extension\ExtensionManager::isLoaded($tmpTSc) ? \TYPO3\CMS\Core\Extension\ExtensionManager::extRelPath($tmpTSc) . 'mod1/db_new_content_el.php' : 'sysext/cms/layout/db_new_content_el.php';
$url = $table == 'pages' || !\TYPO3\CMS\Core\Extension\ExtensionManager::isLoaded('cms') ? 'db_new.php?id=' . $uid . '&pagesOnly=1' : $newContentWizScriptPath . '?id=' . $rec['pid'] . '&sys_language_uid=' . intval($rec['sys_language_uid']);
return $this->linkItem($GLOBALS['LANG']->makeEntities($GLOBALS['LANG']->getLL('CM_newWizard')), $this->excludeIcon(\TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-' . ($table === 'pages' ? 'page' : 'document') . '-new')), $this->urlRefForCM($url, 'returnUrl'), 0);
}