blob: f770c9bbb147c0e74c2d43c7e0436d5b6d9f23d9 [file] [log] [blame]
Andreu66ad5cf2019-09-18 17:15:44 +02001<html>
2 <head>
3 <meta charset="UTF-8">
4 <title>Pàgina de benvinguda</title>
avm99963db383ed2019-09-22 02:14:42 +02005
6 <meta name="viewport" content="width=device-width, initial-scale=1">
7
Andreu66ad5cf2019-09-18 17:15:44 +02008 <link rel="stylesheet" href="./css/basic.css" />
9 <link rel="stylesheet" href="./css/login.css" />
avm99963db383ed2019-09-22 02:14:42 +020010
Andreu0b2f8432019-09-18 20:09:59 +020011 <script src="https://code.jquery.com/jquery-3.4.1.min.js"></script>
Andreu66ad5cf2019-09-18 17:15:44 +020012 </head>
13 <body>
14 <div id="outter-container">
15 <div id="inner-container">
16 <h1>Selecciona el teu nom</h1>
avm99963db383ed2019-09-22 02:14:42 +020017 <p>Per entrar al joc de la Pastanaga Assessina</p>
Andreu09b8b052019-09-21 21:47:20 +020018 <form action="./php/login.php" method="POST">
Andreu0b2f8432019-09-18 20:09:59 +020019 <select name="user" id="list">
Andreu66ad5cf2019-09-18 17:15:44 +020020 </select>
avm99963db383ed2019-09-22 02:14:42 +020021
Andreu20cbd1d2019-09-22 00:00:57 +020022 <input disabled required placeholder="Clau d'accés..." id="password" type="password" name="password"/>
Andreu66ad5cf2019-09-18 17:15:44 +020023 <input type="submit" value="Entrar" />
24 </form>
25 </div>
26 </div>
avm99963db383ed2019-09-22 02:14:42 +020027
Andreu0b2f8432019-09-18 20:09:59 +020028 <script>
Andreuabbcb7e2019-09-21 18:22:14 +020029 $.post("./ajax/getusers.php", function(data, status){
Andreu0b2f8432019-09-18 20:09:59 +020030 $("#list").html(data);
31 });
avm99963db383ed2019-09-22 02:14:42 +020032
Andreu20cbd1d2019-09-22 00:00:57 +020033 $('select').on('change', function() {
34 let nopassword = $('select option:selected').hasClass('nopassword');
35 $('#password').prop('disabled', nopassword);
36 });
Andreu0b2f8432019-09-18 20:09:59 +020037 </script>
Andreu66ad5cf2019-09-18 17:15:44 +020038 </body>
39</html>