Nope, that won't work.
You should never check the existance of a var by
if (!$var)
{
echo "var doesn't exist";
};
Why? because this IF statement checks the value of the var.
Vars only have values if they are set. If the var is not set, this statement will generate a warning.
Moreover, if you used this method to check wether a counter was set, you'd get 'var not set' when you set the counter with value zero.
But,
if(!isset($name) && !isset($password))
You may want to change the && to || because you need both the vars to be set.
You want to print the form when either var is NOT set, or when both vars ARE set.