There are a lot of answers on how to log in as a specific user. But I can't find any answer on how to check if the username and password is valid without logging in. I want to be able to do something like this:
$username = "bla@bla.com"
$password = "blablabla"
$valid = checkIfValidDetails($username, $password);
I simply want $valid = true if the username and password is correct, and false if not.
How can I do that?