[TYPO3-dev] cObj in BE

Steffen Kamper steffen at dislabs.de
Fri Jan 12 22:43:32 CET 2007


Hi olly,

"Oliver Hader" <oh at inpublica.de> schrieb im Newsbeitrag 
news:mailman.1.1168616352.29541.typo3-dev at lists.netfielders.de...
> Hi Steffen,
>
> Steffen Kamper wrote:
>> Hi list,
>>
>> i try for a while to get a local cObj to work in BE.
>> By doing
>> include_once(PATH_site.'typo3/sysext/cms/tslib/class.tslib_content.php');
>> $cObj=t3lib_div::makeInstance('tslib_cObj');
>>
>> the object $GLOBALS['TSFE'] is not filled properly.
>>
>> Do you have any hint how to do it ?
>
> $GLOBALS['TSFE'] is a reference to an instance of tslib_fe
> (tslib/class.tslib_fe.php). $GLOBALS['TSFE']->cObj has the instance of
> tslib_cObj. $GLOBALS['TSFE'] is instantiated in tslib/index_ts.php like
> in this example:
>
>
> $temp_TSFEclassName = t3lib_div::makeInstanceClassName('tslib_fe');
> $TSFE = new $temp_TSFEclassName(
> $TYPO3_CONF_VARS,
> t3lib_div::_GP('id'),
> t3lib_div::_GP('type'),
> t3lib_div::_GP('no_cache'),
> t3lib_div::_GP('cHash'),
> t3lib_div::_GP('jumpurl'),
> t3lib_div::_GP('MP'),
> t3lib_div::_GP('RDCT')
> );
> $TSFE->connectToDB();
>
>
> olly
> -- 
> Oliver Hader
> http://inpublica.de/

good to know, but it doesn't help me for creating a cObj.
If i do it the way described, the TSFE-Object is created too, but i get an 
error in this line:

$page = 
$GLOBALS['TSFE']->sys_page->getPage($link_param,$disableGroupAccessCheck);

so what i want to do: for testing only making a cObj->typolink, the aim is 
to render a single content element in BE.
But something initial is missing, but i don't know what. Maybe you have an 
Idea ?

vg  Steffen 






More information about the TYPO3-dev mailing list