[TYPO3-german] Statische Seite falls T3 nicht auf DB zugreifen kann
Christian Ducrot
ducrot at online.de
Mon Jun 12 11:56:40 CEST 2006
Jörg Käseberg schrieb:
> Ich würde gerne eine statische Seite anzeigen, falls TYPO3 keinen
> Zugriff auf die Datenbank hat.
> Ist das möglich? Wenn ja, wie?
Hallo Jörg,
Quick+Dirty typo3/init.php editieren:
// *************************
// Connect to the database
// *************************
if ($GLOBALS['TYPO3_DB']->sql_pconnect(TYPO3_db_host, TYPO3_db_username, TYPO3_db_password)) {
// OK
// ...
} else {
// OLD: t3lib_BEfunc::typo3PrintError ('The current username, password or host was not accepted when the connection to the database was attempted to be established!','Database Error');
// NEW:
include('my_error_message.html');
exit;
}
Viele Grüße
Christian Ducrot
More information about the TYPO3-german
mailing list