Esempio n. 1
0
    /**
     * Initialize module
     *
     * @return	void
     */
    function init()
    {
        global $BE_USER, $LANG, $BACK_PATH, $TCA_DESCR, $TCA, $CLIENT, $TYPO3_CONF_VARS;
        $this->MCONF = $GLOBALS['MCONF'];
        $this->lF = t3lib_div::makeInstance('t3lib_BEDisplayLog');
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $BACK_PATH;
        $this->doc->setModuleTemplate('templates/belog.html');
        // Load necessary JavaScript
        /** @var $pageRenderer t3lib_PageRenderer */
        $pageRenderer = $this->doc->getPageRenderer();
        $pageRenderer->loadExtJS();
        $pageRenderer->addJsFile($this->backPath . '../t3lib/js/extjs/tceforms.js');
        // Define settings for Date Picker
        $dateFormat = $GLOBALS['TYPO3_CONF_VARS']['SYS']['ddmmyy'];
        $this->dateFormat = $dateFormat . ' ' . $GLOBALS['TYPO3_CONF_VARS']['SYS']['hhmm'];
        $typo3Settings = array('datePickerUSmode' => 0, 'dateFormat' => array($dateFormat, $this->dateFormat));
        $pageRenderer->addInlineSettingArray('', $typo3Settings);
        $this->doc->JScode = '
		<script language="javascript" type="text/javascript">
			script_ended = 0;
			function jumpToUrl(URL)	{
				window.location.href = URL;
			}
		</script>
		';
        $this->doc->tableLayout = array('0' => array('defCol' => array('<td valign="top" class="t3-row-header"><strong>', '</strong></td><td class="t3-row-header"><img src="' . $this->doc->backPath . 'clear.gif" width="10" height="1" alt="" /></td>')), 'defRow' => array('0' => array('<td valign="top">', '</td>'), 'defCol' => array('<td><img src="' . $this->doc->backPath . 'clear.gif" width="10" height="1" alt="" /></td><td valign="top">', '</td>')));
        $this->doc->table_TABLE = '<table border="0" cellspacing="0" cellpadding="0" class="typo3-dblist">';
        $this->doc->form = '<form action="" method="post">';
        $this->menuConfig();
        $this->be_user_Array = t3lib_BEfunc::getUserNames();
        $this->lF->be_user_Array =& $this->be_user_Array;
    }
Esempio n. 2
0
    /**
     * Initialization
     *
     * @return	void
     */
    function init()
    {
        global $BACK_PATH;
        $this->MCONF = $GLOBALS['MCONF'];
        $this->menuConfig();
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $BACK_PATH;
        $this->doc->setModuleTemplate('templates/config.html');
        // JavaScript
        $this->doc->JScode = '
		<script language="javascript" type="text/javascript">
			script_ended = 0;
			function jumpToUrl(URL)	{
				window.location.href = URL;
			}
		</script>
		';
        $this->doc->form = '<form action="" method="post">';
    }
Esempio n. 3
0
    /**
     * Initialization
     *
     * @return	void
     */
    function init()
    {
        $this->MCONF = $GLOBALS['MCONF'];
        $this->menuConfig();
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->form = '<form action="" method="post">';
        $this->doc->backPath = $GLOBALS['BACK_PATH'];
        $this->doc->setModuleTemplate(t3lib_extMgm::extRelPath('indexed_search') . '/mod/mod_template.html');
        // JavaScript
        $this->doc->JScodeArray['indexed_search'] = '
			script_ended = 0;
			function jumpToUrl(URL)	{
				window.location.href = URL;
			}';
        $this->doc->tableLayout = array('defRow' => array('0' => array('<td valign="top" nowrap>', '</td>'), 'defCol' => array('<td><img src="' . $this->doc->backPath . 'clear.gif" width=10 height=1></td><td valign="top" nowrap>', '</td>')));
        $indexer = t3lib_div::makeInstance('tx_indexedsearch_indexer');
        $indexer->initializeExternalParsers();
    }
Esempio n. 4
0
    /**
     * Basic initialization of the class
     *
     * @return	void
     */
    function init()
    {
        $this->MCONF = $GLOBALS['MCONF'];
        $this->menuConfig();
        $this->switchUser(t3lib_div::_GP('SwitchUser'));
        // **************************
        // Initializing
        // **************************
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $GLOBALS['BACK_PATH'];
        $this->doc->setModuleTemplate('templates/beuser.html');
        $this->doc->form = '<form action="" method="post">';
        // JavaScript
        $this->doc->JScode = $this->doc->wrapScriptTags('
			script_ended = 0;
			function jumpToUrl(URL)	{	//
				window.location.href = URL;
			}
		' . $this->doc->redirectUrls());
    }
Esempio n. 5
0
    /**
     * Standard init function of a module.
     *
     * @return	void
     */
    function init()
    {
        global $BACK_PATH, $BE_USER;
        // Setting module configuration:
        $this->MCONF = $GLOBALS['MCONF'];
        // Initialize Document Template object:
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $BACK_PATH;
        $this->doc->setModuleTemplate('templates/ws.html');
        // JavaScript
        $this->doc->JScode = $this->doc->wrapScriptTags('
			script_ended = 0;
			function jumpToUrl(URL)	{	//
				window.location.href = URL;
			}

			function expandCollapse(rowNumber) {
				elementId = "wl_" + rowNumber;
				element = document.getElementById(elementId);
				image = document.getElementById("spanw1_" + rowNumber);
				if (element.style)	{
					if (element.style.display == "none")	{
						element.style.display = "table-row";
						image.className = "t3-icon t3-icon-actions t3-icon-actions-view t3-icon-view-table-collapse";
					} else {
						element.style.display = "none";
						image.className = "t3-icon t3-icon-actions t3-icon-actions-view t3-icon-view-table-expand";
					}
				}
			}
		');
        $this->doc->form = '<form action="index.php" method="post" name="pageform">';
        // Setting up the context sensitive menu:
        $this->doc->getContextMenuCode();
        // Add JS for dynamic tabs:
        $this->doc->JScode .= $this->doc->getDynTabMenuJScode();
        // Setting publish access permission for workspace:
        $this->publishAccess = $BE_USER->workspacePublishAccess($BE_USER->workspace);
        // Parent initialization:
        parent::init();
    }
Esempio n. 6
0
    /**
     * Standard init function of a module.
     *
     * @return	void
     */
    function init()
    {
        global $BE_USER, $LANG, $BACK_PATH, $TYPO3_CONF_VARS;
        /**
         * Extension Categories (static var)
         * Content must be redundant with the same internal variable as in class.tx_extrep.php!
         */
        $this->categories = array('be' => $GLOBALS['LANG']->getLL('category_BE'), 'module' => $GLOBALS['LANG']->getLL('category_BE_modules'), 'fe' => $GLOBALS['LANG']->getLL('category_FE'), 'plugin' => $GLOBALS['LANG']->getLL('category_FE_plugins'), 'misc' => $GLOBALS['LANG']->getLL('category_miscellanous'), 'services' => $GLOBALS['LANG']->getLL('category_services'), 'templates' => $GLOBALS['LANG']->getLL('category_templates'), 'example' => $GLOBALS['LANG']->getLL('category_examples'), 'doc' => $GLOBALS['LANG']->getLL('category_documentation'));
        /**
         * Extension States
         * Content must be redundant with the same internal variable as in class.tx_extrep.php!
         */
        $this->states = tx_em_Tools::getStates();
        $this->script = 'mod.php?M=tools_em';
        $this->privacyNotice = $GLOBALS['LANG']->getLL('privacy_notice');
        $securityMessage = $GLOBALS['LANG']->getLL('security_warning_extensions') . '<br /><br />' . sprintf($GLOBALS['LANG']->getLL('security_descr'), '<a href="http://typo3.org/teams/security/" target="_blank">', '</a>');
        $flashMessage = t3lib_div::makeInstance('t3lib_FlashMessage', $securityMessage, $GLOBALS['LANG']->getLL('security_header'), t3lib_FlashMessage::INFO);
        $this->securityHint = $flashMessage->render();
        $this->excludeForPackaging = $GLOBALS['TYPO3_CONF_VARS']['EXT']['excludeForPackaging'];
        // Setting module configuration:
        $this->MCONF = $GLOBALS['MCONF'];
        // Setting GPvars:
        $this->CMD = is_array(t3lib_div::_GP('CMD')) ? t3lib_div::_GP('CMD') : array();
        $this->lookUpStr = trim(t3lib_div::_GP('lookUp'));
        $this->listRemote = t3lib_div::_GP('ter_connect');
        $this->listRemote_search = trim(t3lib_div::_GP('ter_search'));
        $this->noDocHeader = intval(t3lib_div::_GP('nodoc') > 0);
        $this->settings = t3lib_div::makeInstance('tx_em_Settings');
        $this->install = t3lib_div::makeInstance('tx_em_Install', $this);
        if (t3lib_div::_GP('silentMode') || $this->noDocHeader) {
            $this->CMD['silentMode'] = 1;
            $this->noDocHeader = 1;
        }
        if ($this->CMD['silentMode']) {
            $this->install->setSilentMode(TRUE);
        }
        // Configure menu
        $this->menuConfig();
        // Setting internal static:
        $this->requiredExt = t3lib_div::trimExplode(',', t3lib_extMgm::getRequiredExtensionList(), TRUE);
        // Initialize Document Template object:
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $BACK_PATH;
        $this->doc->setModuleTemplate('templates/em_index.html');
        // Initialize helper objects
        $this->api = t3lib_div::makeInstance('tx_em_API');
        $this->terConnection = t3lib_div::makeInstance('tx_em_Connection_Ter', $this);
        $this->terConnection->wsdlURL = $TYPO3_CONF_VARS['EXT']['em_wsdlURL'];
        $this->xmlHandler = t3lib_div::makeInstance('tx_em_Tools_XmlHandler');
        $this->xmlHandler->emObj = $this;
        $this->xmlHandler->useObsolete = $this->MOD_SETTINGS['display_obsolete'];
        // Initialize newListing
        if (isset($this->MOD_MENU['function']['extensionmanager'])) {
            $this->extensionmanager = t3lib_div::makeInstance('tx_em_ExtensionManager', $this);
        } else {
            $this->extensionmanager =& $this;
        }
        // Output classes
        $this->extensionList = t3lib_div::makeInstance('tx_em_Extensions_List', $this);
        $this->extensionDetails = t3lib_div::makeInstance('tx_em_Extensions_Details', $this);
        $this->translations = t3lib_div::makeInstance('tx_em_Translations', $this);
        // the id is needed for getting same styles TODO: general table styles
        $this->doc->bodyTagId = 'typo3-mod-tools-em-index-php';
        // JavaScript
        $this->doc->JScode = $this->doc->wrapScriptTags('
			script_ended = 0;
			function jumpToUrl(URL)	{	//
				window.location.href = URL;
			}
		');
        // Reload left frame menu
        if ($this->CMD['refreshMenu']) {
            $this->doc->JScode .= $this->doc->wrapScriptTags('
				if(top.refreshMenu) {
					top.refreshMenu();
				} else {
					top.TYPO3ModuleMenu.refreshMenu();
				}
			');
        }
        // Descriptions:
        $this->descrTable = '_MOD_' . $this->MCONF['name'];
        if ($BE_USER->uc['edit_showFieldHelp']) {
            $LANG->loadSingleTableDescription($this->descrTable);
        }
        // Setting username/password etc. for upload-user:
        $this->fe_user['username'] = $this->MOD_SETTINGS['fe_u'];
        $this->fe_user['password'] = $this->MOD_SETTINGS['fe_p'];
        parent::init();
        $this->handleExternalFunctionValue('singleDetails');
    }
    /**
     * Standard init function of a module.
     *
     * @return	void
     */
    function init()
    {
        global $BE_USER, $LANG, $BACK_PATH, $TYPO3_CONF_VARS;
        /**
         * Extension Categories (static var)
         * Content must be redundant with the same internal variable as in class.tx_extrep.php!
         */
        $this->categories = array('be' => $GLOBALS['LANG']->getLL('category_BE'), 'module' => $GLOBALS['LANG']->getLL('category_BE_modules'), 'fe' => $GLOBALS['LANG']->getLL('category_FE'), 'plugin' => $GLOBALS['LANG']->getLL('category_FE_plugins'), 'misc' => $GLOBALS['LANG']->getLL('category_miscellanous'), 'services' => $GLOBALS['LANG']->getLL('category_services'), 'templates' => $GLOBALS['LANG']->getLL('category_templates'), 'example' => $GLOBALS['LANG']->getLL('category_examples'), 'doc' => $GLOBALS['LANG']->getLL('category_documentation'));
        /**
         * Extension States
         * Content must be redundant with the same internal variable as in class.tx_extrep.php!
         */
        $this->states = array('alpha' => $GLOBALS['LANG']->getLL('state_alpha'), 'beta' => $GLOBALS['LANG']->getLL('state_beta'), 'stable' => $GLOBALS['LANG']->getLL('state_stable'), 'experimental' => $GLOBALS['LANG']->getLL('state_experimental'), 'test' => $GLOBALS['LANG']->getLL('state_test'), 'obsolete' => $GLOBALS['LANG']->getLL('state_obsolete'), 'excludeFromUpdates' => $GLOBALS['LANG']->getLL('state_exclude_from_updates'));
        /**
         * "TYPE" information; labels, paths, description etc.
         */
        $this->typeLabels = array('S' => $GLOBALS['LANG']->getLL('type_system'), 'G' => $GLOBALS['LANG']->getLL('type_global'), 'L' => $GLOBALS['LANG']->getLL('type_local'));
        $this->typeDescr = array('S' => $GLOBALS['LANG']->getLL('descr_system'), 'G' => $GLOBALS['LANG']->getLL('descr_global'), 'L' => $GLOBALS['LANG']->getLL('descr_local'));
        // Setting paths of install scopes:
        $this->typePaths = array('S' => TYPO3_mainDir . 'sysext/', 'G' => TYPO3_mainDir . 'ext/', 'L' => 'typo3conf/ext/');
        $this->typeBackPaths = array('S' => '../../../', 'G' => '../../../', 'L' => '../../../../' . TYPO3_mainDir);
        $this->privacyNotice = $GLOBALS['LANG']->getLL('privacy_notice');
        $securityMessage = $GLOBALS['LANG']->getLL('security_warning_extensions') . '<br /><br />' . sprintf($GLOBALS['LANG']->getLL('security_descr'), '<a href="http://typo3.org/teams/security/" target="_blank">', '</a>');
        $flashMessage = t3lib_div::makeInstance('t3lib_FlashMessage', $securityMessage, $GLOBALS['LANG']->getLL('security_header'), t3lib_FlashMessage::INFO);
        $this->securityHint = $flashMessage->render();
        $this->excludeForPackaging = $GLOBALS['TYPO3_CONF_VARS']['EXT']['excludeForPackaging'];
        // Setting module configuration:
        $this->MCONF = $GLOBALS['MCONF'];
        // Setting GPvars:
        $this->CMD = is_array(t3lib_div::_GP('CMD')) ? t3lib_div::_GP('CMD') : array();
        $this->lookUpStr = trim(t3lib_div::_GP('lookUp'));
        $this->listRemote = t3lib_div::_GP('ter_connect');
        $this->listRemote_search = trim(t3lib_div::_GP('ter_search'));
        // Configure menu
        $this->menuConfig();
        // Setting internal static:
        if ($TYPO3_CONF_VARS['EXT']['allowSystemInstall']) {
            $this->systemInstall = 1;
        }
        $this->requiredExt = t3lib_div::trimExplode(',', $TYPO3_CONF_VARS['EXT']['requiredExt'], 1);
        // Initialize helper object
        $this->terConnection = t3lib_div::makeInstance('SC_mod_tools_em_terconnection');
        $this->terConnection->emObj = $this;
        $this->terConnection->wsdlURL = $TYPO3_CONF_VARS['EXT']['em_wsdlURL'];
        $this->xmlhandler = t3lib_div::makeInstance('SC_mod_tools_em_xmlhandler');
        $this->xmlhandler->emObj = $this;
        $this->xmlhandler->useObsolete = $this->MOD_SETTINGS['display_obsolete'];
        // Initialize Document Template object:
        $this->doc = t3lib_div::makeInstance('template');
        $this->doc->backPath = $BACK_PATH;
        $this->doc->setModuleTemplate('templates/em_index.html');
        // JavaScript
        $this->doc->JScode = $this->doc->wrapScriptTags('
			script_ended = 0;
			function jumpToUrl(URL)	{	//
				window.location.href = URL;
			}
		');
        // Reload left frame menu
        if ($this->CMD['refreshMenu']) {
            $this->doc->JScode .= $this->doc->wrapScriptTags('
				if(top.refreshMenu) {
					top.refreshMenu();
				} else {
					top.TYPO3ModuleMenu.refreshMenu();
				}
			');
        }
        // Descriptions:
        $this->descrTable = '_MOD_' . $this->MCONF['name'];
        if ($BE_USER->uc['edit_showFieldHelp']) {
            $LANG->loadSingleTableDescription($this->descrTable);
        }
        // Setting username/password etc. for upload-user:
        $this->fe_user['username'] = $this->MOD_SETTINGS['fe_u'];
        $this->fe_user['password'] = $this->MOD_SETTINGS['fe_p'];
        parent::init();
        $this->handleExternalFunctionValue('singleDetails');
    }