> Ok, I have created a package that takes orders and creates temporary
> files. Upon completing the order, the temp files are deleted. If the
> user does not complete the order and leaves the web site, the files
> remain as clutter. 
> 
> How can I tell if a user has left the site and act upon it?
> If a user only gets half way through the order process and decides
> he/she is ready to go-to another site; How can I tell the system to
> erase their left-over files?

No you can't tell the user left to another site. 

You could try playing with JavaScript onUnLoad handlers, change the 
external links so that they go through a script that does something 
and redirects to the actual address, but I would not recommend that. 
You will miss some and you will delete others that you do not want to 
(imagine they open the external link into a new window, or that they 
create a new window, your page gets loaded into that second window 
and when the user moves someplace else you delete the file ... while 
he still has the first window open).

The best you can do is to run a background job from time to time and 
delete the files that were not modified for some time.

Jenda
=========== [EMAIL PROTECTED] == http://Jenda.Krynicky.cz ==========
There is a reason for living. There must be. I've seen it somewhere.
It's just that in the mess on my table ... and in my brain
I can't find it.
                                        --- me


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to