What potential security risks are associated with not encrypting passwords in PHP form submissions?

Not encrypting passwords in PHP form submissions can lead to security risks such as exposing sensitive user data to potential hackers if the data is intercepted during transmission. To mitigate this risk, passwords should be encrypted before being submitted to the server using a secure hashing algorithm like bcrypt.

$password = $_POST['password'];
$hashed_password = password_hash($password, PASSWORD_DEFAULT);
// Store $hashed_password in the database