in reply to Re^4: Keep running script but ending it to the browser
in thread Keep running script but ending it to the browser

No probs.

It shouldn't do that ...

  1. The last & on the line puts the command (sleep 15 ; rm $tempfile >/dev/null 2>&1) into background
  2. nohup (short for, AFAIR, 'no hangup') 'informs' the scheduler that the background shell is to run to completion i.e. not to be terminated, when its controlling process (in this case, the perl script) terminates.

You might want to 'play around' with the quoting, e.g....

system "nohup 'sleep 15 ; rm $tempfile 2>&1' &";
The variable _will_ be interpolated because the single quotes are part of a double quoted string :-)

HTH ,

A user level that continues to overstate my experience :-))