Hallo,
ich benötige für ein Backend-Modul eine Selectbox mit allen Ländern. Im Frontend habe ich das mit der Extension static_info_tables und den Funktionen initCountries bzw. buildStaticInfoSelector gelöst. Wie mache ich das am besten fürs Backend?
Viele Grüße
Morla
Die beiden Funktionen sind in einer Klasse fürs Frontend drin. Wenn ich sie genauso im Backend aufrufe, erhalte ich Fehlermeldungen.
So steht es in der Dokumentation fürs Frontend:
$staticInfoObj = &t3lib_div::getUserObj('&tx_staticinfotables_pi1');
if ($staticInfoObj->needsInit() {
$staticInfoObj->init();
}
$staticInfoObj->buildStaticInfoSelector('COUNTRIES', $fieldName, $CSSClassName, $selectedCountryCode, '', $submitFlag, $id, $title, $where, $lang, $local);
Das erzeugt bei mir Fehlermeldungen im Backend:
Warning: require_once(PATH_tslibclass.tslib_pibase.php) [function.require-once]: failed to open stream: No such file or directory in ...\typo3conf\ext\static_info_tables\pi1\class.tx_staticinfotables_pi1.php on line 63
Fatal error: require_once() [function.require]: Failed opening required 'PATH_tslibclass.tslib_pibase.php' (include_path='.;...\php\pear\') in ...\typo3conf\ext\static_info_tables\pi1\class.tx_staticinfotables_pi1.php on line 63
achso sry,
wenn das in einem be-module sein soll, kommst du um eine manuellen aufruf des selects fast nicht rum.
oder brauchst du es wo anders?