Ok.. maybe this would help if I posted my login function, this will not work, and I do not know why. Whenever I try to login, it doesn't work - always returns a wrong password. I copied the encrypted md5 password and salt directly from my account in the vb user table, and put it into my site's users table.. under my account.
PHP Code:
function login(){ if (!$_POST[login]) { global $Ybox; $Ybox->top("Welcome Guest"); echo("<form method='POST' style='margin: 0px;'> <div style='text-align: center; padding: 3px;'> Username: <br> <input type='text' size='15' maxlength='25' $read name='username'><br> Password: <br> <input type='password' size='15' maxlength='25' $read name='password'><br> </div> <br> <center><input type='submit' name='login' value='Login'> <input type='reset' name='reset' value='Reset'><br><br> </form> <a href='/register/'>Register</a> | <a href='/forgotpass/'>Forgot Password?</a></center>"); $Ybox->stop(); }else{ $username = safe($_POST["username"]); $info = mysql_query("SELECT * FROM users WHERE username = '$username'") or die(mysql_error()); $data = mysql_fetch_array($info); $pass5 = md5($_POST['password']); $password = ($pass5 . $data[salt]); $passcheck = ($data[password] . $data[salt]); if($data[password] != $password) { global $Nav; Bbox ("Error","Incorrect Username or Password, Please go back and fix this."); }else{ Rbox("Success","<center>Please wait as you are being logged in!</center>"); } } }