It might be worth printing out your POST array to confirm that your values are setting as you think.
print_r($_POST);
should do the job at the top of the script. Once you confirm that you are setting the variables I would suggest adding debug as you work your way down through the IF statement.
That way you can ensure that the variables arent getting changed by the sanitise process.
From what you are saying it would look as if the login process fails and therefore continue to load the form.
You might want to add an else section to the
if($admin_obj->login($admin_username, $admin_password, &$error)){
section to just echo out a nice simple, failed to login so continuing to load form.
So in short add some extra debug temporarily to help narrow down the problem.