Changeset 504 for branches/htmlform/cgi-bin/main.cgi
- Timestamp:
- 09/27/11 13:01:55 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/htmlform/cgi-bin/main.cgi
r503 r504 701 701 " block size for the pool."; 702 702 } else { 703 if (!$webvar{pop}) { 704 $page->param(err => 'Please select a POP to route the block from/through.'); 705 return; 706 } 703 707 $city = $webvar{pop}; 704 708 $failmsg = "No suitable free block found.<br>\nYou will have to route another". … … 845 849 sub validateInput { 846 850 if ($webvar{city} eq '-') { 847 printError("Please choose a city.");851 $page->param(err => 'Please choose a city'); 848 852 return; 849 853 } … … 854 858 # Danger! Danger! alloctype should ALWAYS be set by a dropdown. Anyone 855 859 # managing to call things in such a way as to cause this deserves a cryptic error. 856 printError("Invalid alloctype");860 $page->param(err => 'Invalid alloctype'); 857 861 return; 858 862 } … … 862 866 if ($def_custids{$webvar{alloctype}} eq '') { 863 867 if (!$webvar{custid}) { 864 printError("Please enter a customer ID.");868 $page->param(err => 'Please enter a customer ID.'); 865 869 return; 866 870 } … … 871 875 my $status = CustIDCK->custid_exist($webvar{custid}); 872 876 if ($CustIDCK::Error) { 873 printError("Error verifying customer ID: ".$CustIDCK::ErrMsg);877 $page->param(err => "Error verifying customer ID: ".$CustIDCK::ErrMsg); 874 878 return; 875 879 } 876 880 if (!$status) { 877 printError("Customer ID not valid. Make sure the Customer ID ".881 $page->param(err => "Customer ID not valid. Make sure the Customer ID ". 878 882 "is correct.<br>\nUse STAFF for staff static IPs, and $IPDB::defcustid for any other ". 879 883 "non-customer assignments."); … … 907 911 } 908 912 } 913 914 # if the alloctype has a restricted city/POP list as determined above, 915 # and the reqested city/POP does not match that list, complain 909 916 if ($flag ne 'n') { 910 printError("Please choose a valid POP location $flag. Valid ".917 $page->param(err => "Please choose a valid POP location $flag. Valid ". 911 918 "POP locations are currently:<br>\n".join (" - ", @poplist)); 912 919 return; … … 1141 1148 # Serves'em right for getting here... 1142 1149 if (!defined($webvar{block})) { 1143 printError("Error 332");1150 $page->param(err => "Can't delete a block that doesn't exist"); 1144 1151 return; 1145 1152 }
Note:
See TracChangeset
for help on using the changeset viewer.