more updates

This commit is contained in:
yi12345
2013-07-01 15:30:50 +03:00
parent 4a7210b1c0
commit ee6f0bfb92
3 changed files with 8 additions and 130 deletions
+2 -2
View File
@@ -20,11 +20,11 @@ class MYSQL_DB {
function register($username, $password, $email, $tribe, $act) {
$time = time();
$timep = time() + PROTECTION;
$stime = strtotime(START_DATE)+strtotime(START_TIME)-time();
$stime = strtotime(START_DATE)-strtotime(date('m/d/Y'))+strtotime(START_TIME);
if($stime > time()){
$time = $stime;
}
$timep = $time + PROTECTION;
$q = "INSERT INTO " . TB_PREFIX . "users (username,password,access,email,timestamp,tribe,act,protect,lastupdate,regtime) VALUES ('$username', '$password', " . USER . ", '$email', $time, $tribe, '$act', $timep, $time, $time)";
if(mysql_query($q, $this->connection)) {
return mysql_insert_id($this->connection);
+2 -2
View File
@@ -23,11 +23,11 @@ class MYSQLi_DB {
function register($username, $password, $email, $tribe, $act) {
$time = time();
$timep = time() + PROTECTION;
$stime = strtotime(START_DATE)+strtotime(START_TIME)-time();
$stime = strtotime(START_DATE)-strtotime(date('m/d/Y'))+strtotime(START_TIME);
if($stime > time()){
$time = $stime;
}
$timep = $time + PROTECTION;
$q = "INSERT INTO " . TB_PREFIX . "users (username,password,access,email,timestamp,tribe,act,protect,lastupdate,regtime) VALUES ('$username', '$password', " . USER . ", '$email', $time, $tribe, '$act', $timep, $time, $time)";
if(mysql_query($this->connection, $q)) {
return mysql_insert_id($this->connection);