start(); $TRANSACTION_ID = $Session->get("TRANSACTION_ID"); require("util.php"); include "newmime.class"; $sql = new MySQL_class; $sql->Create("lavendise"); if ($logout != $nothing){ session_destroy(); } ?> Your Lavendise Workspace





The Gateway

 The Gateway
The Sanctuary
The Grove

What's New
MessageBoards
Live Chat
Houses
Faery Lands
Fae Love
Books
Music

Query("Select * FROM user_security WHERE sessionID = '$TRANSACTION_ID'"); $checkrows = $sql->rows; if ($checkrows > 0){ $sql->Fetch(0); $userid = $sql->data[0]; echo ''; exit(); } } //*********************************************** // Login Check //*********************************************** if ($login != $nothing){ $sql->Query("Select * FROM users WHERE username = '$username'"); $checkrows = $sql->rows; if ($checkrows > 0){ $sql->Fetch(0); $userid = $sql->data[0]; $sql->Query("Select * FROM users WHERE username = '$username' and password = '$password'"); $checkrows2 = $sql->rows; if ($checkrows2 < 1){ $logerror=2; } }else{ $logerror=1; } if($logerror == $nothing){ $SESSION = array(); $SESSION['trn_id32'] = md5(uniqid(rand(),1)); $TRANSACTION_ID=$SESSION['trn_id32']; session_register("TRANSACTION_ID"); $sql->Update("update user_security set sessionID = '$TRANSACTION_ID' where user_ID = '$userid'"); echo ''; exit(); } } //*********************************************** // Forgot Info //*********************************************** if ($mailme == 1){ $sql->Query("Select * FROM users WHERE email = '$email'"); $checkrows = $sql->rows; if ($checkrows > 0){ $sql->Fetch(0); $username = $sql->data[1]; $password = $sql->data[2]; $mime=new mime_email(); $to = "$email"; $subject = "Lavendise Account Info"; $body = ("Lavendise Account Info \n\n username: $username \n\n password: $password \n"); # send e-mail mail($to,$subject,$body,$nemail."\r\n".$header); echo"

Your info was emailed to you.

"; }else{ echo"

We couldn't find your account, try a different email address.

"; $forgot=1; } $username = $nothing; $password = $nothing; } if ($forgot == 1){ echo"Enter your email address you used to signup with and we will mail your login info to you.

Email Address
"; exit(); } //*********************************************** // Validate reg form //*********************************************** if ($reg == 1){ if (ereg('^[[:alnum:]@._]+$', $username)) { }else{ $uerror = 1; } if (ereg('^[[:alnum:]]+$', $password)) { }else{ $uerror = 2; } if (strlen($username) < 4 || strlen($password) < 4){ $uerror = 3; } if ($uerror == $nothing){ $sql->Query("SELECT username FROM users WHERE username = '".$username."'"); $exists = $sql->rows; if($exists != 0){ $uexists = 1; }else{ $cdate = date("Y-m-d"); $sql->INSERT("INSERT INTO users(username, password, first_name, last_name, email, webaddress) VALUES('$username','$password','$fname','$lname','$email','$webaddress')"); $userid = mysql_insert_id(); $now = date("Y-m-d"); $sql->INSERT("INSERT INTO user_security(user_id, security_level, institute_id, joined) VALUES('$userid','s','1','$now')"); $editid = mysql_insert_id(); $SESSION = array(); $SESSION['trn_id32'] = md5(uniqid(rand(),1)); $TRANSACTION_ID=$SESSION['trn_id32']; session_register("TRANSACTION_ID"); $sql->Update("update user_security set sessionID = '$TRANSACTION_ID' where user_ID = '$userid'"); echo ''; exit(); } } $reg = $nothing; } //*********************************************** // Display reg form //*********************************************** if ($reg == $nothing){ if ($uerror == 1){ $_text = "Your Username contains invaild characters."; } if ($uerror == 2){ $_text = "Your Password contains invaild characters."; } if ($uerror == 3){ $_text = "Your Username or Password is less than 4 characters."; } if($uexists == 1){ $_text = 'Username allready exists, please try another.'; } if ($logerror == 1){ $_text = "That username doesn't exist."; } if ($logerror == 2){ $_text = "Your Password is incorrect."; } ?> "; if ($sessionid == $nothing && $apply == $nothing){ echo"You are not logged in. You must login to edit your webring settings.
If you do not have an account with Lavendise and wish to join The Fairy Ring, then
Click Here to register for a new account.

Forgot your login info? Click Here."; echo"

"; echo"
USERNAME:
PASSWORD:
"; exit(); } echo"
USERNAME:
PASSWORD:
FIRST NAME:
LAST NAME:
EMAIL:
WEBADDRESS:
"; }