Webrick: save on shutdown

(Maarten Boonen) #1

Hi all,

I am running a HTTPServer and use my browser to change some data that's
loaded from an XML file. Now, I'm saving the data back to the same file
each time a change is made to it, but I like to do this only once, when
I shutdown the server (which I do by closing the Windows command
prompt). I tried redefining the shutdown procedure, but no luck there.
Is there a simple way to do this?

Thanks in advance,
Maarten