The problem is, is that even if I enter correct codes it will still pop the login screen, then eventually say "Authorization Required".
<?php
session_start();
include('functions.php');
if ($_SESSION['auth'] == 'true') {
PrintTop();
ListInfos();
PrintEnd();
exit;
} else {
if ((!isset( $PHP_AUTH_USER )) || (!isset($PHP_AUTH_PW)) || ( $PHP_AUTH_USER != 'BooYa' ) || ( $PHP_AUTH_PW != 'Cheeze' ) ) {
header( 'WWW-Authenticate: Basic realm="Private"' );
header( 'HTTP/1.0 401 Unauthorized' );
echo 'Authorization Required.';
exit;
} else {
$_SESSION['auth'] = 'true';
PrintTop();
ListInfos();
PrintEnd();
exit;
}
}
?>