當前位置: 首頁>>代碼示例>>PHP>>正文


PHP ExtensionManager::addFieldsToUserSettings方法代碼示例

本文整理匯總了PHP中TYPO3\CMS\Core\Extension\ExtensionManager::addFieldsToUserSettings方法的典型用法代碼示例。如果您正苦於以下問題:PHP ExtensionManager::addFieldsToUserSettings方法的具體用法?PHP ExtensionManager::addFieldsToUserSettings怎麽用?PHP ExtensionManager::addFieldsToUserSettings使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在TYPO3\CMS\Core\Extension\ExtensionManager的用法示例。


在下文中一共展示了ExtensionManager::addFieldsToUserSettings方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: die

<?php

// Make sure that we are executed only from the inside of TYPO3
if (!defined('TYPO3_MODE')) {
    die('Access denied.');
}
// Prepare new columns for be_users table
$tempColumns = array('tx_openid_openid' => array('exclude' => 0, 'label' => 'LLL:EXT:openid/locallang_db.xml:be_users.tx_openid_openid', 'config' => array('type' => 'input', 'size' => '30', 'eval' => 'trim,nospace,unique')));
// Add new columns to be_users table
\TYPO3\CMS\Core\Utility\GeneralUtility::loadTCA('be_users');
\TYPO3\CMS\Core\Extension\ExtensionManager::addTCAcolumns('be_users', $tempColumns, FALSE);
\TYPO3\CMS\Core\Extension\ExtensionManager::addToAllTCAtypes('be_users', 'tx_openid_openid;;;;1-1-1', '', 'after:username');
\TYPO3\CMS\Core\Extension\ExtensionManager::addLLrefForTCAdescr('be_users', 'EXT:' . $_EXTKEY . '/locallang_csh.xml');
// Prepare new columns for fe_users table
$tempColumns['tx_openid_openid']['config']['eval'] = 'trim,nospace,uniqueInPid';
// Add new columns to fe_users table
\TYPO3\CMS\Core\Utility\GeneralUtility::loadTCA('fe_users');
\TYPO3\CMS\Core\Extension\ExtensionManager::addTCAcolumns('fe_users', $tempColumns, FALSE);
\TYPO3\CMS\Core\Extension\ExtensionManager::addFieldsToAllPalettesOfField('fe_users', 'username', 'tx_openid_openid');
\TYPO3\CMS\Core\Extension\ExtensionManager::addLLrefForTCAdescr('fe_users', 'EXT:' . $_EXTKEY . '/locallang_csh.xml');
// Add field to setup module
$GLOBALS['TYPO3_USER_SETTINGS']['columns']['tx_openid_openid'] = array('type' => 'user', 'table' => 'be_users', 'label' => 'LLL:EXT:openid/locallang_db.xml:_MOD_user_setup.tx_openid_openid', 'csh' => 'tx_openid_openid', 'userFunc' => 'EXT:openid/class.tx_openid_mod_setup.php:TYPO3\\CMS\\Openid\\OpenidModuleSetup->renderOpenID', 'access' => 'TYPO3\\CMS\\Openid\\OpenidModuleSetup');
\TYPO3\CMS\Core\Extension\ExtensionManager::addFieldsToUserSettings('tx_openid_openid', 'after:password2');
\TYPO3\CMS\Core\Extension\ExtensionManager::addLLrefForTCAdescr('_MOD_user_setup', 'EXT:openid/locallang_csh_mod.xml');
開發者ID:noxludo,項目名稱:TYPO3v4-Core,代碼行數:24,代碼來源:ext_tables.php


注:本文中的TYPO3\CMS\Core\Extension\ExtensionManager::addFieldsToUserSettings方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。