Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.
 
 
 
 

30 rindas
1.1 KiB

  1. <?php
  2. include "header.php";
  3. connecte("ecomonde");
  4. $pseudo=$_POST['pseudo'];
  5. $pass=sha1($_POST['password']);
  6. $email=$_POST['email'];
  7. $hash=md5($email);
  8. $check_email=requete1l("SELECT * FROM membres WHERE email='$email'");
  9. if ($check_email) {
  10. header("location:index.php?msg=2");
  11. }
  12. else {
  13. $latest_commit = file_get_contents('./version.txt');
  14. $sql="INSERT INTO membres VALUES(NULL,'$pseudo','$pass','$email','$latest_commit')";
  15. mysql_query($sql) or die("ERREUR !");
  16. mkdir("medias/".$hash."/");
  17. mkdir("medias/".$hash."/enemy/");
  18. copy("medias/default/index.php", "medias/".$hash."/index.php");
  19. copy("medias/default/player.xml", "medias/".$hash."/player.xml");
  20. copy("medias/default/map.jpg", "medias/".$hash."/map.jpg");
  21. copy("medias/default/soft.mp3", "medias/".$hash."/soft.mp3");
  22. copy("medias/default/tonic.mp3", "medias/".$hash."/tonic.mp3");
  23. copy("medias/default/hard.mp3", "medias/".$hash."/hard.mp3");
  24. copy("medias/default/light.mp3", "medias/".$hash."/light.mp3");
  25. copy("medias/default/dark.mp3", "medias/".$hash."/dark.mp3");
  26. header("location:index.php?msg=1");
  27. }
  28. ?>