[TYPO3-english] Howto access TS Setup by condition userFunc?
Hendrik
h.reimers at neonaut.de
Fri Feb 4 08:27:22 CET 2011
Hi,
i want to access the full typoscript with a condition userfunc, but i
have problems to solve that.
i've tried the following:
// Require classes
require_once(PATH_t3lib.'class.t3lib_page.php');
require_once(PATH_t3lib.'class.t3lib_tstemplate.php');
require_once(PATH_t3lib.'class.t3lib_tsparser_ext.php');
// Init page id and the page object
$pid = intval( (( $pageUid > 0 ) ? $pageUid :
t3lib_div::_GP('id')) );
$obj_page = t3lib_div::makeInstance('t3lib_pageSelect');
// Init agregrated TypoScript
$rootline = $obj_page->getRootLine($pid);
if (empty($rootline)) return false;
$obj_TypoScript = t3lib_div::makeInstance('t3lib_tsparser_ext');
$obj_TypoScript->tt_track = 0;
$obj_TypoScript->init();
$obj_TypoScript->runThroughTemplates($rootline);
$obj_TypoScript->generateConfig();
die(print_r($obj_TypoScript->setup));
return $obj_TypoScript->setup;
But this doens't work... it starts with a very long loadtime and ends
with a php memory limit error (php.ini memory_limit is 1024M).
can anyone help me please?
thanks a lot...
henny
More information about the TYPO3-english
mailing list