• Unfortunately, we have experienced significant hard drive damage that requires urgent maintenance and rebuilding. The forum will be a state of read only until we install our new drives and rebuild all the configurations needed. Please follow our Facebook page for updates, we will be back up shortly! (The forum could go offline at any given time due to the nature of the failed drives whilst awaiting the upgrades.) When you see an Incapsula error, you know we are in the process of migration.

Register php Season 8

Newbie Spellweaver
Joined
Aug 27, 2011
Messages
12
Reaction score
0
Good night, I need help setting up the registry do station 8 do pangya,
The configuration is below.
If someone can help me
Or if someone already has a ready and able to share it will be welcome.

PHP:
<?php 

$login = $_POST['login'];
$senha = MD5($_POST['senha']);
$connect = mysql_connect('test','root','123456'); or die("Error Connect to Database");
$db = mysql_select_db('account');
$query_select = "SELECT login FROM usuarios WHERE login = '$login'";
$select = mysql_query($query_select,$connect);
$array = mysql_fetch_array($select);
$logarray = $array['login'];

  if($login == "" || $login == null){
    echo"<script language='javascript' type='text/javascript'>alert('O campo login deve ser preenchido');window.location.href='cadastro.html';</script>";

    }else{
      if($logarray == $login){

        echo"<script language='javascript' type='text/javascript'>alert('Esse login já existe');window.location.href='cadastro.html';</script>";
        die();

      }else{
        $query = "INSERT INTO usuarios (login,senha) VALUES ('$login','$senha')";
        $insert = mysql_query($query,$connect);
        
        if($insert){
          echo"<script language='javascript' type='text/javascript'>alert('Usuário PangYa Club foi cadastrado com Sucesso!!');window.location.href='login.html'</script>";
        }else{
          echo"<script language='javascript' type='text/javascript'>alert('Não foi possível cadastrar esse usuário');window.location.href='cadastro.html'</script>";
        }
      }
    }
?>
 
Junior Spellweaver
Joined
Jun 22, 2015
Messages
140
Reaction score
32
possivelmente irar dar erro quando tentar se cadastrar ! vai no meu mp e compartilha esse site, eu ajudo a melhorar e configurar corretamente : ) // Possibly irar to give error when to try to register! Go in my mp and share this site, I help improve and configure correctly:)
 
Upvote 0
Back
Top