/** * Creates this object. */ public function __construct() { if (class_exists('t3lib_utility_VersionNumber')) { if (tx_ttnews_compatibility::int_from_ver(TYPO3_version) >= 6000000) { $this->isVersion6 = TRUE; } } }
/** * Reads the [extDir]/locallang.xml and returns the $LOCAL_LANG array found in that file. * * @return The array with language labels */ function includeLocalLang() { $llFile = t3lib_extMgm::extPath('newssdf') . 'locallang.xml'; // Patch suggested by Marc Neuhaus on forge, concerning TYPO3 v. 6.0 compatibility; Manually applied by RICC $LOCAL_LANG = tx_ttnews_compatibility::getInstance()->readLLXMLfile($llFile, $GLOBALS['LANG']->lang); //$LOCAL_LANG = t3lib_div::readLLXMLfile($llFile, $GLOBALS['LANG']->lang); return $LOCAL_LANG; }
/** * @return tx_ttnews_compatibility */ protected function compatibility() { return tx_ttnews_compatibility::getInstance(); }
/** * Includes the locallang file for the 'tt_news' extension * * @return array The LOCAL_LANG array */ function includeLocalLang() { $llFile = t3lib_extMgm::extPath('tt_news') . 'locallang.xml'; $LOCAL_LANG = tx_ttnews_compatibility::getInstance()->readLLXMLfile($llFile, $GLOBALS['LANG']->lang); return $LOCAL_LANG; }
* This copyright notice MUST APPEAR in all copies of the script! ***************************************************************/ /** * AJAX dispatcher * * @author Rupert Germann <*****@*****.**> * @author Benjamin Mack <*****@*****.**> * @package TYPO3 * * $Id$ * */ $TYPO3_AJAX = true; require 'conf.php'; require $BACK_PATH . 'init.php'; if (tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) < 6002000) { require_once PATH_typo3 . 'classes/class.typo3ajax.php'; require_once PATH_typo3 . 'sysext/lang/lang.php'; } $GLOBALS['LANG'] = t3lib_div::makeInstance('language'); $GLOBALS['LANG']->init($GLOBALS['BE_USER']->uc['lang']); // finding the script path from the variable $ajaxID = (string) t3lib_div::_GP('ajaxID'); $ajaxScript = $TYPO3_CONF_VARS['BE']['AJAX'][$ajaxID]; // instantiating the AJAX object //if (tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) >= 4003000) { $ajaxObj = t3lib_div::makeInstance('TYPO3AJAX', $ajaxID); //} else { // $ajaxClassName = t3lib_div::makeInstanceClassName('TYPO3AJAX'); // $ajaxObj = new $ajaxClassName($ajaxID); //}
t3lib_extMgm::addTCAcolumns('be_users', $tempColumns, 1); t3lib_extMgm::addToAllTCAtypes('be_users', 'tt_news_categorymounts;;;;1-1-1'); if (TYPO3_MODE == 'BE') { // if (tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) >= 4000000) { // if (tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) >= 4002000) { t3lib_extMgm::addModule('web', 'txttnewsM1', '', t3lib_extMgm::extPath($_EXTKEY) . 'mod1/'); $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['cms']['db_layout']['addTables'][$_EXTKEY][0]['fList'] = 'uid,title,author,category,datetime,archivedate,tstamp'; $GLOBALS['TYPO3_CONF_VARS']['EXTCONF']['cms']['db_layout']['addTables'][$_EXTKEY][0]['icon'] = TRUE; // } // register contextmenu for the tt_news category manager $GLOBALS['TBE_MODULES_EXT']['xMOD_alt_clickmenu']['extendCMclasses'][] = array('name' => 'tx_ttnewscatmanager_cm1', 'path' => t3lib_extMgm::extPath($_EXTKEY) . 'cm1/class.tx_ttnewscatmanager_cm1.php'); // } // Adds a tt_news wizard icon to the content element wizard. $TBE_MODULES_EXT['xMOD_db_new_content_el']['addElClasses']['tx_ttnews_wizicon'] = t3lib_extMgm::extPath($_EXTKEY) . 'pi/class.tx_ttnews_wizicon.php'; // add folder icon // if (tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) < 4004000) { // $ICON_TYPES['news'] = array('icon' => t3lib_extMgm::extRelPath($_EXTKEY) . 'res/gfx/ext_icon_ttnews_folder.gif'); // } else { t3lib_SpriteManager::addTcaTypeIcon('pages', 'contains-news', t3lib_extMgm::extRelPath($_EXTKEY) . 'res/gfx/ext_icon_ttnews_folder.gif'); // } if (TYPO3_UseCachingFramework || tx_ttnews_compatibility::getInstance()->int_from_ver(TYPO3_version) >= 6000000) { // register the cache in BE so it will be cleared with "clear all caches" try { $GLOBALS['typo3CacheFactory']->create('tt_news_cache', $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['tt_news_cache']['frontend'], $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['tt_news_cache']['backend'], $GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['tt_news_cache']['options']); } catch (t3lib_cache_exception_DuplicateIdentifier $e) { // do nothing, a tt_news_cache cache already exists } } } // register HTML template for the tt_news BackEnd Module $GLOBALS['TBE_STYLES']['htmlTemplates']['mod_ttnews_admin.html'] = t3lib_extMgm::extRelPath('tt_news') . 'mod1/mod_ttnews_admin.html';
/** * [Describe function...] * * @return [type] ... */ function includeLocalLang() { $llFile = t3lib_extMgm::extPath('tt_news') . 'cm1/locallang.xml'; $this->LL = tx_ttnews_compatibility::getInstance()->readLLXMLfile($llFile, $GLOBALS['LANG']->lang); }