... include
Ich machs normalerweise so ...
file: config.inc.php {
$user = "test";
$pwd = "test";
$db = "Datenbank";
$table = "test";
}
file: classconnect.inc.php {
function connect($user, $pwd, $db) {
.. Aufbau zur Datenbank ...
}
file: index.php {
include "config.inc.php";
include "classconnect.inc.php";
$db = new connect();
// Aufbau Datenbank
if (!$db->connect($user, $pwd, $db))
echo "fehler ...";
... Inhalt ...
}
Headerlocation verwende ich eigentlich nur um eine andere Seite aufzurufen ...
Gruss,
schera
|