What are some common pitfalls to avoid when working with password hashing in PHP?

One common pitfall to avoid when working with password hashing in PHP is using outdated hashing algorithms like MD5 or SHA1, which are no longer considered secure. It is recommended to use the `password_hash()` function with the `PASSWORD_DEFAULT` algorithm for secure password hashing. Additionally, make sure to properly store and verify hashed passwords to prevent security vulnerabilities.

// Hashing a password using password_hash() function
$password = "secretPassword";
$hashedPassword = password_hash($password, PASSWORD_DEFAULT);

// Verifying a password using password_verify() function
$enteredPassword = "secretPassword";
if (password_verify($enteredPassword, $hashedPassword)) {
    echo "Password is correct";
} else {
    echo "Password is incorrect";
}