Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <form action="index.php" method="post" name="login">
- <script type="text/javascript">
- function delayer(){
- window.location = "/projects/index.php"
- }
- </script>
- </head>
- <?php
- $user = $_POST['Username'];
- $password = $_POST['Password'];
- $filename = "data.php";
- if (file_exists('data.php')) {
- echo "Profile, more coming soon! This is basically a system where it makes a database for you.";
- $db = sqlite_open('data.php');
- if ($user == "");
- {
- header('Refresh: 4; url=index.php');
- unlink($filename);
- echo "You forgot to enter your username.";
- }
- if ($password = "");
- {
- header('Refresh: 4; url=index.php');
- unlink($filename);
- echo "You forgot to enter your password.";
- }
- sqlite_query($db,"INSERT INTO data (user, pass)VALUES('$user', '$password')");
- }
- else
- {
- ?>
- <h2>Welcome to the oli project. </h2>
- <p>Your portable database will be generated within 3 seconds, you will be redirected.</p>
- <p>Please wait..<p>
- <label>Username</label><input name="Username" type="text" class="input" size="30" /><br />
- <label>Password</label><input name="Password" type="password" class="input" size="30" /><br />
- <label> </label><input name="Submit" type="submit" class="button" />
- <?
- $database = new SQLiteDatabase('data.php');
- $sql = 'CREATE TABLE data (id INTEGER PRIMARY KEY, user TEXT, pass TEXT, key TEXT)';
- $sql1 = 'CREATE TABLE admins (id INTEGER PRIMARY KEY, user TEXT)';
- $database->queryExec($sql);
- $database->queryExec($sql1);
- }
- ?>
Add Comment
Please, Sign In to add comment