I have no idea why you would want to so inconvenience the user, but anway.
Either sessions or cookies would work.
Session may be better because users can always delete cookies.
session_start();
session_register('forceLogIn');
if($_SESSION[forceLogIn]=="" || $_SESSION[forceLogIn]==0){
// session var is blank or equal to zero
// build log in form, don't display user info
}
The way that works, if the var has not value, it is likely the first time they are at the page, so naturaly they have to log in.
On sucessful log in, $forceLogIn is set to zero.
Hope that helps.