Bug #17730 Updated: PEAR_Error in HTML_Table

From: Date: Fri, 19 Jul 2002 15:21:44 +0000
Subject: Bug #17730 Updated: PEAR_Error in HTML_Table
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-7789@lists.php.net to get a copy of this message
ID: 17730 Updated by: mansion@php.net Reported By: wima@tiscalinet.ch -Status: Open +Status: Closed Bug Type: PEAR related Operating System: All PHP Version: 4.2.1 New Comment: This bug has been fixed in CVS. You can grab a snapshot of the CVS version at http://snaps.php.net/. In case this was a documentation problem, the fix will show up soon at http://www.php.net/manual/. In case this was a PHP.net website problem, the change will show up on the PHP.net site and on the mirror sites. Thank you for the report, and for helping us make PHP better. As far as I understand German, I hope this is now fixed in CVS. You might want to test it to confirm. Thanks for the feedback. Bertrand Mansion Mamasam Previous Comments: ------------------------------------------------------------------------ [2002-06-12 12:08:44] wima@tiscalinet.ch I think its wrong to create an error with return new PEAR_Error("Error"); It shoult be created with PEAR::raiseError(). Sorry about my english. Here is the article from de.comp.lang.php: > Hallo > Ich verstehe noch nicht ganz, wie das mit dem Pear-Error gemeint ist. Mit > PEAR::setErrorHandling(PEAR_ERROR_CALLBACK,'handle_pear_error'); kann ich > den Error-Handler definieren, das klappt auch. Aber z.B. bei der > Table-Klasse wird bei einem Fehler ein PEAR_Error Objekt zurückgegeben > (return new PEAR_Error("First parameter to HTML_Table::addRow must be an > array");). Nun geht das irgendwie an meinem eigenen Handler vorbei, er wird > gar nicht aufgerufen. Der Konstruktor von PEAR_Error weiss ja gar nicht, > dass ich das Handling mit PEAR_ERROR_CALLBACK definiert habe. > Danke für eure Hilfe. > Marco Hi, ich würde dies als Bug bezeichnen, denn ein PEAR_Error sollte nicht per "new" erstellt werden, sondern per PEAR::raiseError(). Wende dich entweder an pear-dev oder bugs.php.net ... (Rubrik PEAR- related) Christian Dickmann ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=17730&edit=1

« previous php.pear.dev (#7789) next »