1. Save the script as and.pl in the PERLSCRIPTS folder.

    Here's what the relevant lines in this script do:
  • if ($request{'username'} eq $user && $request{'pass'} eq $pass)

    Uses the AND operator:

    &&

    to compare two conditions.

    It’s asking:

    Is the word entered in the textbox named username the same as the word assigned to the variable $user?

    AND

    Is the word entered in the textbox named password the same as the word assigned to the variable $pass?

    If both these things are true, then execute the code in the curly braces.

  1. Upload and.pl to the perlscripts directory on the Web server, then set its permissions so that anyone can execute it.
  2. In the browser, go to:

    www.yourwebsite.com/and.html