- Joined
- Sep 21, 2007
- Messages
- 58
- Reaction score
- 7
How can i do it ?
<?php
// By PeChU!!
if(stristr($_SERVER['PHP_SELF'], "config.php")) die('<center><b><h1><font color=red>Buraya Biraz Zor Girersiniz... :) Admin : [GM]Admin</font></h1></b></center>');
$host = "localhost or My Wan Ip"; // host mysql
$user = "root"; // username
$pass = "root"; // password
$db = "databasename"; // database name
mysql_connect($host,$user,$pass) or die(mysql_error());
mysql_select_db($db) or die(mysql_error());
function nw($N, $C){
$reg = mysql_query("INSERT INTO accounts (username, password, accesslevel) VALUES( '$N', '$C', '100')")or die(mysql_error());
return $reg;
}
function exi($user){
$check = mysql_query("SELECT * FROM accounts WHERE username = '$user'");
$check2 = mysql_num_rows($check);
return $check2;
}
?>