Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- include("../config.php");
- $lock = "installer.lock";
- if (!file_exists($lock)) {
- $connection = mysql_connect($host, $username, $password);
- if (!$connection) { die('Could not connect: ' . mysql_error()); }
- else {
- echo "Connected!";
- mysql_select_db($database, $connection);
- $query = "CREATE TABLE {$prefix}members
- (
- Username varchar(15),
- Password varchar(15),
- Email varchar(255),
- Admin int
- )";
- if (mysql_query($query, $connection)) {
- echo "Success!";
- mysql_close($close, $connection); }
- else { echo "Failure! :("; }
- // Create Installer Lock
- $file = "installer.lock";
- $handle = fopen($file, "w") or die("Can't open File");
- fclose($handle);
- }}
- else {
- echo "The Installer is locked. Please delete installer.lock before continuing";
- }
- ?>
- <title>Installer</title>
Add Comment
Please, Sign In to add comment