[Classiccity-pm] Timeout

Linda Dubes Law lindadl at uga.edu
Thu Mar 2 09:30:41 PST 2006


Paul Keck made me join this list because he was jealous of Leslie Grove
because she got to have all the fun of helping me solve all of my
interesting perl problems.  Just kidding.  

Here is today's problem:

Running on HP/UX, certain users login and are thrown into a perl menu
script.  They can go from there to other perl scripts that I want to time
out after a very short time compared to the menu.  They can also go to third
party software but always end up back at this menu and thrown out of the
system when they quit the menu.  The third party software has its own
timeout function that works great and has to stay because many of the users
only see the third party software.  Not everyone gets the pleasure of seeing
the results of my scripts. 

Anyway, is there something that I can put between these two lines that will
kick the user out of the system while the script is waiting for input?

print "\n\n 	Q or q to quit : ";

chomp ($task = <STDIN>);


Thanks, 

Linda Law

**************

#!/usr/contrib/bin/perl

use Shell;

# $SIG{INT} = 'IGNORE'; 

while ($task ne 'Q' and $task ne 'q') 
{

system (clear);
	
print "    BULLDOG BUCKS MAIN MENU\n\n";

print "	 1. Go to the OPTIM program\n";
print "	 2. Add 1 card holder to the system\n";
print "	 3. Add a Library Print and Copy Card Range\n";
print "	 4. *Add 1 Departmental Card\n";
print "	 5. *Add Housing Summer Camp Card Range\n";
print "	 6. *Change Plan and Reset Balance for 1 Cardholder\n";
print "	 7. *View and/or print last daily email sent to a location\n";
print "	 8. *Get Cardholder Notes by Status Code and Date\n";
print "	 9. Lock a user account\n";
print "	10. Unlock a user account\n";

print "\n\n	    * indicates the option is not yet ready for use.";

print "\n\n 	Q or q to quit : ";

chomp ($task = <STDIN>);

SWITCH:
{
	($task eq '1')	&& do 	{



More information about the Classiccity-pm mailing list