Home : Products : Gossamer Links : PHP Front End :

Products: Gossamer Links: PHP Front End: Setting register_shutdown_function in Class: Edit Log

Here is the list of edits for this post
Setting register_shutdown_function in Class

I have a working class with functions etc and would like to run a particular function in it after any function within the class is run.

So far... I can successfully place this call inside each individual function of the class and it will run DESTROY on exit of that particular function:

register_shutdown_function(array(&$this, 'DESTROY'));

But what I want to do is register this just once at the top of the script, just after the class name, so it applies to every function within the class - without having to include it in every function.

I have tried the above line but it gives errors, I have also tried this but it's giving error also:


Can anyone show me the correct way to do this to make it work?


Last edited by:

ryel01: Nov 12, 2005, 12:34 AM

Edit Log: