Help for this page

Select Code to Download


  1. or download this
    <Directory D:/www/data/private>
    AuthType Basic
    ...
    AuthUserFile D:/www/passwd.txt
    Require user Nikos
    </Directory>
    
  2. or download this
    <Location D:/www/cgi-bin/make.pl>
    AuthType Basic
    ...
    AuthUserFile D:/www/passwd.txt
    Require user Nikos
    </Location>
    
  3. or download this
    print header(-status=>'401 Unauthorized', 'WWW-Authenticate'=>'Basic r
    +ealm="Restricted Games"') unless $ENV{REMOTE_USER};
    exit unless $ENV{REMOTE_USER};
    
    #Restricted code - this code will not run unless user is authenticated
    +. Test $ENV{REMOTE_USER} for user-level control
    print header(), "Authenticated User: $ENV{REMOTE_USER}\n";