php3-list | 199908
Date: 08/04/99
- Next message: Mansour Jarbou: "[PHP3] eval() question"
- Previous message: Terry Carmen: "[PHP3] ! Linking HELP!"
- In reply to: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Next in thread: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Reply: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Reply: Zeev Suraski: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello Rasmus,
On 04-Aug-99 18:14:59, you wrote:
>> I did not invent this situation. It happened to me while using PostgreSQL
>> transactions. I had to resort to register_shutdown_function() to end any
>> pending transactions. It worked but it was a lame solution even because
>> register_shutdown_function only lets you register one function at a time
>> and you might need more. There's another thing to be improved.
>Why would you need more than one? With a little logic you can make that
Because you may nedd to cleanup for completely unrelated parts of your
scripts.
>function do all the cleanup you need.
That's what I did to solve the problem then. Actually I even have built a
registration table that would handle removing registration entries and
would be able to pass context to each of the registered shutdown functions.
One of the problems is that I had to resort to global variables. That's
fine as long I don't use somebody else's code that uses the same global
variable names.
Another problem is if you borrow code that also sets registers a shutdown
function overriding yours or vice versa.
It may happen and you might not be aware of the clash if you don't study
throughly the code you are borrowing.
PHP could be more flexible here if you reckon that these situations might
be problematic. Usually I don't borrow much code, but I am certain tha a
lot of people that is not skilled enough just borrow code from everywhere
to solve their problems and are not aware of these situations.
Regards,
Manuel Lemos
Web Programming Components using PHP Classes.
Look at: email protected>?subject=Re:%20[PHP3]%20Re:%20[PHP4BETA]%20Re:%20[PHP3]%20OO&replyto=1823.885T283T9503020mlemos <email protected>">mlemos <email protected>">http://phpclasses.UpperDesign.com/?user=mlemos <email protected>
-- E-mail: mlemos <email protected> URL: http://www.mlemos.e-na.net/ PGP key: http://www.mlemos.e-na.net/ManuelLemos.pgp ---- PHP 3 Mailing List <http://www.php.net/> To unsubscribe, send an empty message to php3-unsubscribe <email protected> To subscribe to the digest, e-mail: php3-digest-subscribe <email protected> To search the mailing list archive, go to: http://www.php.net/mailsearch.php3 To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: Mansour Jarbou: "[PHP3] eval() question"
- Previous message: Terry Carmen: "[PHP3] ! Linking HELP!"
- In reply to: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Next in thread: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Reply: Rasmus Lerdorf: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Reply: Zeev Suraski: "Re: [PHP3] Re: [PHP4BETA] Re: [PHP3] OO"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

