How can the variables $_SERVER["PHP_AUTH_USER"] and $_SERVER["PHP_AUTH_PW"] be cleared after logging out in PHP?

When a user logs out in PHP, the variables $_SERVER["PHP_AUTH_USER"] and $_SERVER["PHP_AUTH_PW"] are not automatically cleared. To clear these variables, you can unset them using the unset() function in PHP. This will remove the values stored in the $_SERVER superglobal array and effectively log the user out.

unset($_SERVER["PHP_AUTH_USER"]);
unset($_SERVER["PHP_AUTH_PW"]);