addresses #1
directories are working users still have dependencies to database code
This commit is contained in:
parent
5e60bf4a9a
commit
7bffc8bf97
12 changed files with 168 additions and 183 deletions
|
@ -31,18 +31,5 @@
|
|||
include_once('common.inc.php');
|
||||
|
||||
header("Content-Type: text/html; charset=UTF-8");
|
||||
try {
|
||||
$dbh = new PDO($dsn, $dbuser, $dbpass);
|
||||
$query = $dbh->prepare("SELECT firstname, lastname FROM dav_password WHERE username=:username");
|
||||
$currentuser = $_SERVER['PHP_AUTH_USER'];
|
||||
$query->execute(array(":username" => $currentuser));
|
||||
$row = $query->fetch(PDO::FETCH_ASSOC);
|
||||
$smarty->assign("firstname", $row['firstname']);
|
||||
$smarty->assign("lastname", $row['lastname']);
|
||||
$smarty->display("start.html");
|
||||
$dbh = null;
|
||||
} catch (PDOException $e) {
|
||||
$smarty->setErrorMsg($e->getMessage());
|
||||
$smarty->display("error.html");
|
||||
}
|
||||
$smarty->display("start.html");
|
||||
?>
|
Loading…
Add table
Add a link
Reference in a new issue