[TYPO3-core] RFC: Bug #11166: loadPrototype() called in frontend editing without a valid doc instance.

Jeff Segars jsegars at alumni.rice.edu
Thu May 28 20:05:49 CEST 2009


Oliver Hader wrote:
> Hi Jeff,
> 
> Jeff Segars schrieb:
>> We've seen this sort of problem pop up several times now, so I think the
>> best solution is create a dummy instance of $GLOBALS['SOBE']->doc in the
>> frontend context so that we don't have to worry about frontend or
>> backend when using tceforms. The attached patch adds a new tsfeDoc to
>> typo3/template.php and creates a dummy version of $GLOBALS['SOBE']
>> within tceforms_fe.
> 
> Thanks for the patch. I'm not happy with a t3lib_TCEforms_dummy class
> and multiple classes in one PHP file. The purpose of this object is just
> to contain a reference to the template instance in $this->doc.
> I've changed this to use an anonymous object that just has $this->doc as
> member variable.
> 
> Besides that: +1 on reading and testing
> 
> olly

Nice idea!  Totally forgot about the ability to use stdClass.


More information about the TYPO3-team-core mailing list