[TYPO3-dev] Programmatically include static template

Adrien Crivelli adrien.crivelli at gmail.com
Wed Aug 1 14:22:26 CEST 2012


Hello,

Is there a way to programmatically include static template from an
extension so it is always loaded and user does not need to include it
manually from backend ?

t3lib_extMgm::addStaticFile()<http://api.typo3.org/typo3v4/45/html/classt3lib__ext_mgm.html#a13ee6921557e1123c328a7dd3df9c576>
only makes it available in backend to be manually included, it does not
actually load it.

t3lib_extMgm::addTypoScriptSetup()<http://api.typo3.org/typo3v4/45/html/classt3lib__ext_mgm.html#a759ae01c02ac89d9b94300384871ba5a>
t3lib_extMgm::addTypoScriptConstants()<http://api.typo3.org/typo3v4/45/html/classt3lib__ext_mgm.html#a05505e7c16c4a7c0d47c531a8436d096>
and I am not exactly sure what those two methods are supposed to do. That
would seem to be what I am looking for, however the page type defined in my
setup.txt is not read, leading to a "The page is not configured" error.

This is my current ext_tables.php file:

t3lib_extMgm::addTypoScriptSetup('<INCLUDE_TYPOSCRIPT:
source="FILE:EXT:newsletter/Configuration/TypoScript/setup.txt">');
t3lib_extMgm::addTypoScriptConstants('<INCLUDE_TYPOSCRIPT:
source="FILE:EXT:newsletter/Configuration/TypoScript/constants.txt">');

t3lib_extMgm::addStaticFile($_EXTKEY, 'Configuration/TypoScript',
'Newsletter');


TIA,

Adrien



More information about the TYPO3-dev mailing list