Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html lang="fr">
- <head> <meta charset="utf-8"/>
- <title>Mon profil</title>
- <body>
- <h2 class="h2" ,align="center">Bienvenue a mon profile </h2>
- <div id="row">
- <img src="avatar2.png" alt="Avatar" style="width:20%"/>
- <div class="btnRow">
- <input type="submit" name="edit" value="editer mon profile" class="ed" id="edited">
- </div>
- <div class="btnRow">
- <input type="submit" value="deconnexion" class="dec" id="deco">
- </div>
- <div id="container">
- <ul>
- <?php
- $nom_bdd = "artizana";
- $server = "localhost";
- $user = "root";
- $password = "";
- $id = $_GET['id'];
- $connexion = new PDO("mysql:host=$server;dbname=$nom_bdd", $user, $password);
- $requete_sql = "SELECT * FROM artisan WHERE id_artisan = ".$id;
- $result = $connexion->query($requete_sql);
- $afficher_profil = $result->fetch();
- echo"
- <li>Nom : ".$afficher_profil['nom']." </li>
- <li>Metrier : ".$afficher_profil['type_artisan']." </li>
- <li>ville: ".$afficher_profil['adresse']." </li>";
- ?>
- </ul>
- <table>
- <?php
- $requete_sql2 = "SELECT * FROM picture WHERE id_art = ".$id;
- $result2 = $connexion->prepare($requete_sql2);
- $afficher_public = $result2->fetch();
- var_dump($afficher_public);
- while( $afficher_public->fetch(PDO::FETCH_ASSOC)) {
- echo"
- <tr> <td>".$afficher_public['contenue']."</td>
- <td>".$afficher_public['description']."</td>
- </tr>";
- }
- ?>
- </table>
- </div>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement