Hallo zusammen,
habe grade ein kleines Problem, bei dem ich mich entweder blöd anstelle oder ersteres.
Es geht sich um folgendes:
Ich habe ein USER-Skript das auf tt_address zurückgreift.
Sinnigerweise mit makeInstance('tx_ttaddress_pi1') instanziiert.
Seltsamerweise wird die Klasse nicht gefunden, obwohl das Statische Template hierfür als allererstes bzw. an oberster Stelle auf der Root-Seite eingebunden ist.
Sobald ich die PHP-Datei per Require einbunden habe, geht das dann auch.
Nachdem aber das Objekt instanziiert ist, fehlt dem... naja, so ziemlich alles. Beim cObj mal angefangen.
Ich hatte das zuvor in einer 6.1.7 Installation ausprobiert, da hat es noch funktioniert...
Vielleicht kann mich einer mit 'nem guten Tipp voranbringen?
<?php namespace meinNamespace; class meineMessen { protected static $initiation = false; protected static $abspath = ''; public function __construct() { } protected function main() { require_once 'typo3conf/ext/tt_address/pi1/class.tx_ttaddress_pi1.php'; } self::$initiation = true; } public function show($content,$conf) { $this->main(); $tt_addr = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('tx_ttaddress_pi1',$content,$conf); $tt_addr->main(); } } ?>
Ausgabe: Fatal error: Call to a member function stdWrap() on a non-object in /var/www/vhosts/www.gemu-group.com/htdocs/typo3conf/ext/tt_address/pi1/class.tx_ttaddress_pi1.php on line 181 Dump von $tt_addr: tx_ttaddress_pi1 prefixId => 'tx_ttaddress_pi1' (16 chars) scriptRelPath => 'pi1/class.tx_ttaddress_pi1.php' (30 chars) extKey => 'tt_address' (10 chars) pi_checkCHash => TRUE conf => NULL ffData => NULL cObj => NULL LOCAL_LANG_loaded => 0 (integer) LLkey => 'de' (2 chars) altLLkey => '' (0 chars) LLtestPrefix => '' (0 chars) LLtestPrefixAlt => '' (0 chars) pi_isOnlyFields => 'mode,pointer' (12 chars) pi_alwaysPrev => 0 (integer) pi_lowerThan => 5 (integer) pi_moreParams => '' (0 chars) pi_listFields => '*' (1 chars) pi_autoCacheEn => 0 (integer) pi_USER_INT_obj => FALSE pi_EPtemp_cObj => NULL pi_tmpPageId => 0 (integer)
P.S:. Typo3 6.2.4
God's in his heaven, all's right with the world