„threadr/profile/edit.php“ ändern
parent
5023fa34fd
commit
9e80ae43ed
|
@ -1,34 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
session_start();
|
|
||||||
%SET_LOGIN_VARIABLE%
|
|
||||||
%PLEAZE_NO_CACHE%
|
|
||||||
%NO_CHEAP_SESSION_STEALING%
|
|
||||||
%REQUIRE_LOGIN%
|
%REQUIRE_LOGIN%
|
||||||
|
|
||||||
$pdo = new PDO('mysql:host=localhost;dbname=web', 'webstuff', 'Schei// auf Pa$$w0rter!');
|
|
||||||
$statement = $pdo->prepare('SELECT name FROM users WHERE id = :user_id;'); // to be replaced with optional user name off the user data table
|
|
||||||
$result = $statement->execute(array('user_id' => $_SESSION['user_id']));
|
|
||||||
$dbentry = $statement->fetch();
|
|
||||||
$username = $dbentry['name'];
|
|
||||||
|
|
||||||
$navbar = "profile";
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<html>
|
|
||||||
<head>
|
|
||||||
<title>ThreadR - Edit Profile</title>
|
|
||||||
%STYLESHEET%
|
|
||||||
<link rel="icon" type="image/png" href="%CONTENT_DIR%/img/favicon-32x32.png" sizes="32x32" />
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
||||||
</head>
|
|
||||||
|
|
||||||
<body>
|
|
||||||
%NAVBAR%
|
|
||||||
<div class="container">
|
|
||||||
<div class="item-1">
|
|
||||||
<center><h1>ThreadR</h1></center>
|
|
||||||
</div>
|
|
||||||
<div class="item-2">
|
|
||||||
<section>
|
<section>
|
||||||
<center><h1><?php echo " $username "; ?> </h1></center>
|
<center><h1><?php echo " $username "; ?> </h1></center>
|
||||||
<form action="%CONTENT_DIR%/profile/" method="post">
|
<form action="%CONTENT_DIR%/profile/" method="post">
|
||||||
|
@ -39,8 +12,4 @@ $navbar = "profile";
|
||||||
<button>Save Profile</button>
|
<button>Save Profile</button>
|
||||||
</form>
|
</form>
|
||||||
</section>
|
</section>
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue