Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php session_start();
- include('header.php');
- if(!empty($_POST['changetokens'])) {
- Membre::profilVisibilite($_SESSION['id'], 'tokens');
- }
- if(!empty($_POST['changeEmail'])) {
- Membre::profilVisibilite($_SESSION['id'], 'email');
- }
- if(!empty($_POST['maj'])) {
- extract($_POST);
- if(Message::interdit($description)) {
- if(filter_var($email, FILTER_VALIDATE_EMAIL)) {
- Membre::majProfil($_SESSION['id'], $tokens, $email);
- }
- else {
- $err = '<span class="error-info">Votre adresse email n\'est pas conforme,<br />veuillez recommencer la mise à jour de votre profil.</span>';
- }
- }
- else {
- $err = '<span class="error-info">Votre description contient du language SMS ou des mots interdits,<br />veuillez recommencer la mise à jour de votre profil.</span>';
- }
- }
- include('menu.php');
- echo '<form action="" method="post">
- <div class="profil-wrap">
- <div class="title">Votre profil <span class="exp-pseudo"> '.Membre::info($_SESSION['id'], 'pseudo').'</span></div>
- ';
- if(!empty($err)) {
- echo '<div class="list">
- '.$err.'
- </div>';
- }
- ?>
- <?php
- UPDATE "nombdd"
- SET tokens = tokens + 1
- WHERE id = 2;
- ?>
- <div class="clear"><div class="list"><input type="submit" value="Mettre le profil à jour" name="maj" class="maj-confirm"></div></div>
- </div>
- </div>
- </form>';
- <?php
- include('footer.php');
- ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement