Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- ob_start();
- session_start();
- $username=$_SESSION['username'];
- include_once"includes/db_connect.php";
- include_once"includes/functions.php";
- logincheck();
- function random(){
- $upper = array('1','2','3','4','5','6','7','8','9');
- $lower = array('a','b','c','d','e','f','g','h','i','j','k','l','m','n','o','p','q','r','s','t','u','v','w','x','y','z');
- $numba = array('0','1','2','3','4','5','6','7','8','9');
- for($x = 0; $x <= 2; $x++){
- $random .= $upper[rand(0, count($lower) - 1)].$lower[rand(0, count($upper) - 1)].$numba[rand(0, count($numba) - 1)];
- }
- return $random;
- }
- $coder = random();
- if(isset($_POST['code'], $_POST['real'])){
- $code = strip_tags($_POST['code']);
- $real = strip_tags($_POST['real']);
- if($code != $real){
- echo 'Code does not match.';
- } else {
- mysql_query("UPDATE `users` SET status='Dead' WHERE `username`='".$_SESSION['username']."'");
- session_destroy();
- header('Location: /');
- exit;
- }
- }
- ?>
- <form action="" method="post">
- <input type="text" disabled="disabled" value="<?php echo $coder; ?>" />
- <input type="hidden" name="real" value="<?php echo $coder; ?>" /><br />
- Enter the code you see above:<br />
- <input type="text" name="code" /><br />
- <input type="submit" value="Suicide" />
- </form>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement