1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68
| <?php
session_start();
$bdd = new PDO('mysql:host=localhost;dbname=name', 'user', 'mdp');
$getps = $_GET['pseudo'];
if(isset($_GET['id']) AND $_GET['id'] > 0) {
$getid = intval($_GET['id']);
$requser = $bdd->prepare('SELECT * FROM membres WHERE id = ?');
$requser->execute(array($getid));
$userinfo = $requser->fetch();
?>
<html>
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<meta name="viewport" content="user-scalable=no" />
<title>Forum test</title>
<meta name="description" content="Forum"/>
<meta name="keywords" content="" />
<link rel="icon" type="image/png" href="images/favicon.png">
<link rel="stylesheet" type="text/css" href="msg.css" />
<link rel="stylesheet" type="text/css" href="profil.css" />
<div id="menu" style="margin-left: 510px"><ul>
<li>
<a class="mainTopNav__item" href="/actu.php"><img src="/images/news.png" style="width: 30px;"><br />Actu</a>
</li>
<li>
<a class="mainTopNav__item" href="/profil.php?id=<?php echo $_SESSION['id']; ?>&pseudo=<?php echo $_SESSION['pseudo']; ?>"><img src="/images/user.png" style="width: 30px;"><br />Moi</a>
</li>
<li>
<div id="menumessage" style="position: absolute;"><a class="mainTopNav__item" href="/reception.php"><img src="/images/message.png" style="width: 30px;"><br />Messages</a></div>
</li>
</ul>
</div>
<br />
<br />
</head>
<body>
<div id="bande">
<img src="/membres/avatars/<?php echo $userinfo['avatar'] ?>" class="logo" style="no-repeat center center/100% white;border-radius: 50%;display: inline-block;float: left;position: absolute;top: 375;left: 250;z-index: 200;border: 3px solid #19c589;padding: 3px;-webkit-border-radius: 150px;width: 4em;height: 4em;">
<div id="bandepseudo" style="display: inline-block; float: left; position: absolute; top: 350; display: inline-table; padding-right: 21px; background-color: #fff; -webkit-border-top-right-radius: 350px; -webkit-border-bottom-right-radius: 350px; -moz-border-radius-topright: 350px; -moz-border=-radius-bottomright: 350px; border-top-right-radius: 350px; border-bottom-right-radius: 350px; height: 71px; box-shadow: 0 6px 10px rgba(0,0,0,.23),0 10px 30px rgba(0,0,0,.19); left: 360; padding-left: 30px; width: auto; min-width: 200px;">
<h2><div id="bandetext" style="position: relative; top: 18;">Profil de <?php echo $userinfo['pseudo']; ?></div></h2></div>
<br />
<div id="data" style="padding-left: 5px; padding-right: 5px;">
Pseudo : <?php echo $userinfo['pseudo']; ?>
<?php
if($_SESSION['pseudo'] == $userinfo['pseudo']) {
echo ' <br> '; echo ' Email : '; echo $userinfo['mail'];
}
?>
<br />
Date de naissance : <?php echo $userinfo['date_naissance']; ?>
<br />
Autre(s) : <center><?php echo $userinfo['autres']; ?></center>
</div>
<br />
</p>
</form>
</div>
</div>
<br />
<br />
<br />
</body>
</html>
<?php
}
?> |
Partager