Hey All!!
I have created a Simple Account creation page!!
Heres the Demo:
Account Registeration Page
and heres a guide on installing it to your server:
Open home.php, and edit the things in RED!!
Code:
<html>
<body>
<?php
error_reporting(E_ALL);
$name = $_POST['username'];
$pass = $_POST['password'];
$email = $_POST['email'];
$flags=0;
if(!empty($_POST['TBC'])){
$flags+=8;
}
if(!empty($_POST['WotLK'])){
$flags+=24;
}
mysql_connect("Database Host","DB Username","DB Password");
mysql_select_db("Youraccountdatabase");
if(mysql_num_rows(mysql_query("SELECT * FROM `accounts` WHERE `login`='$name'"))>0){
echo "Please Choose another Username.";
}else{
if(mysql_query("INSERT INTO accounts (login, password, email,flags) VALUES('$name', '$pass', '$email', '$flags' ) ")){
echo"Your Account has been created Successfully";
}else{
echo"Please Try Again.";
}
}
?>
</body>
</html>
Open INDEX.HTML and Edit:
Code:
<html>
<head>
<link rel="stylesheet" type="text/css"
href="account.css" />
</head>
<title>
Account Registeration Page
</title>
<body>
<body>
<h1>Account Creation Page</h1>
<h2>Site Navigation:</h2>
<p1>
<br>
<a href="http://LinkToYourHomePage">Home</a>
</br>
<br>
<a href="http://LinkTOYourForums">Forums</a>
</br>
<br>
<a href="http://LinkToYourAccountRegisterationPage">Registeration</a>
</br>
</p1>
<center>
<font color="GoldenRod"><font size="4"><b>
<form name="input" action="home.php" method="post">
<fieldset>
<legend>Create Your Account here:</legend><p>
Username:
<input type="text" name="username">
<br>
Password:
<input type="text" name="password">
<br>
Email-ID:
<input type="text" name="email">
<p>
Burning Crusade
<input type="checkbox" name= "TBC" value="tb">
</p>
<p>
Wrath of the Lich King
<input type="checkbox" name="WotLK" value="ww">
</p>
<p>
<br>
<input type="submit" value="Submit">
</p></p>
</fieldset>
</form>
<p2>Set Realmlist Whateverisyourrealmlist</p2>
</font>
</body>
</body>
</center>
</html>
Close, and save both of your files.
Make sure all 3 Files;
index.html, home.php and account.css is in your HTDOCS or WWW folder.
All Credit goes to me!
Thank You! :-)
DOWNLOAD NOW:
MEGAUPLOAD - The leading online storage and file delivery service