Advertisement
Guest User

Untitled

a guest
Mar 14th, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.35 KB | None | 0 0
  1. <?php
  2. $host="localhost";
  3. $user="root";
  4. $password="";
  5. $adb="prisijungimai";
  6.  
  7. mysql_connect($host,$user,$password);
  8. mysql_select_db($adb);
  9. if(isset($_POST['userid'])){
  10. $uname=$_POST['userid'];
  11. $password=$_POST['pswrd'];
  12. $sql="select * from prisijungimas where user='".$uname."'AND Pass ='".$password."'
  13. limit 1";
  14. $result=mysql_query($sql);
  15. if(mysql_num_rows($result)==1){
  16. echo " Sekmingai prisijungete";
  17. exit();
  18. }
  19. else{
  20. echo " Blogas prisijungimas arba slaptazdois";
  21.  
  22. }
  23. }
  24. ?>
  25.  
  26. <!doctype html>
  27. <html>
  28. <head>
  29. <title>Batoneliu svetaine</title>
  30. <style type="text/css"></style>
  31.  
  32.  
  33. <link rel="stylesheet" type="text/css" href="style.css">
  34.  
  35.  
  36.  
  37. <meta charset="=utf-8">
  38. </head>
  39. <body>
  40.  
  41. <button class="button">Namai</button>
  42. <button class="button">Prekes</button>
  43. <button class="button">Kontaktai</button>
  44. <input type="submit" class="button" value="Pristatymas">
  45.  
  46. <div>
  47.  
  48. </div>
  49.  
  50.  
  51. <div class="body"></div>
  52. <div class="grad"></div>
  53. <div class="header">
  54.  
  55. </div>
  56. <br>
  57. <div class="login">
  58. <form action="" method="POST">
  59. <input type="text" placeholder="Prisijungimas" name="userid"><br>
  60. <input type="password" placeholder="Slaptazodis" name="pswrd"><br>
  61. <input type="submit" onclick="check(this.form)" value="Login"/>
  62. </form>
  63. </div>
  64.  
  65.  
  66.  
  67.  
  68. </body>
  69.  
  70. </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement