# -*- perl -*-
if ($maintdir == "") $maintdir = "..";
require("$maintdir/constants.php3");
require("$authdir/perror-list.php3");
# Print out an error message
if ($ERRNO <> "") {
printf("
\n");
switch($ERRNO) {
case -1:
case $ERR_NO_ERROR:
break;
case $ERR_FIELD_MISSING:
printf("Please enter something in all the data fields\n");
break;
case $ERR_FIELD_MISSING_BACK:
printf("Please enter something in all the data fields -- -- use \"back\" button on your browser\n");
break;
case $ERR_NO_ACCESS:
printf("You do not appear to be logged in\n");
break;
case $ERR_RESTRICTED_ACCESS:
printf("Sorry, you do not have access to this area\n");
break;
case $ERR_NO_COOKIE_GIVEN:
printf("For some reason, you did not get a cookie!\n");
break;
case $ERR_NO_SUCH_VALUE:
printf("Sorry, there is no such value\n");
break;
case $ERR_PW_EXPIRED:
printf("Your password has expired. You will need to contact the system administrator to renew your password ($adminemail).\n");
break;
case $ERR_COOKIE_EXPIRED:
printf("Your cookie has expired. Please re-login.\n");
break;
case $ERR_BAD_PW:
printf("Incorrect username / password combination\n");
break;
case $ERR_NO_SUCH_AFSID:
printf("Sorry, no such AFS ID exists\n");
break;
case $ERR_AFSID_ALREADY_IN_USE:
printf("It seems that someone has already registered that AFS ID.
Perhaps you have forgotten your password?\n");
break;
case $ERR_PW_MISMATCH:
printf("The two passwords that you typed did not match. Please try again.\n");
break;
case $ERR_NO_AFSID_SUPPLIED:
printf("You must enter your AFS ID\n");
break;
case $ERR_NO_DEPT_SELECTED:
printf("You must select a department\n");
break;
case $ERR_NO_OLDPW_SUPPLIED:
printf("You must enter your old password\n");
break;
case $ERR_CHANGES_SAVED:
printf("Your changes have been saved\n");
break;
case $ERR_MUST_CHOOSE:
printf("You must choose one of the options listed\n");
break;
case $ERR_MUST_SUPPLY_WRITEIN:
printf("If you select the \"writein\" option, you must supply a name in the text box\n");
break;
case $ERR_WAY_MUCKED_UP:
default:
printf("Something is really wrong here -- please contact the system administrator ($adminemail) with information about what happened here!\n");
break;
}
printf("\n\n");
}
?>