[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml restore-exception-handler.xml

2005-11-29 Thread Jakub Vrana
vrana   Tue Nov 29 08:36:54 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
restore-exception-handler.xml 
  Log:
  Missing fullstop
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.12&r2=1.13&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.12 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.13
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.12  
Sun Apr 24 19:19:35 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Nov 
29 08:36:54 2005
@@ -1,5 +1,5 @@
 
-
+
 
 
  
@@ -23,7 +23,7 @@
  
   &reftitle.returnvalues;
   
-   This function always returns &true;
+   This function always returns &true;.
   
  
 
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml?r1=1.5&r2=1.6&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml
diff -u 
phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.5 
phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.6
--- phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.5   
Sun Apr 24 19:19:35 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml   
Tue Nov 29 08:36:54 2005
@@ -1,5 +1,5 @@
 
-
+
 
  
   restore_exception_handler
@@ -25,7 +25,7 @@
  
   &reftitle.returnvalues;
   
-   This function always returns &true;
+   This function always returns &true;.
   
   
  


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread Jakub Vrana
vrana   Tue Apr  5 09:08:56 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
  Log:
  Calling restore_error_handler() from the error_handler function is ignored 
(bug #31675)
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.9&r2=1.10&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.9 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.10
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.9   
Tue Apr  5 08:00:24 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Apr 
 5 09:08:56 2005
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -20,6 +20,12 @@
  handler (which could be the built-in or a user defined function). This
  function always returns &true;.
 
+
+ 
+  Calling restore_error_handler from the
+  error_handler function is ignored.
+ 
+
 
  See also error_reporting,
  set_error_handler,


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread Jakub Vrana
vrana   Tue Apr  5 08:00:25 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
  Log:
  Meaningful example different from set_error_handler
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.8&r2=1.9&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.8 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.9
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.8   
Tue Apr  5 06:51:53 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Apr 
 5 08:00:24 2005
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -27,58 +27,30 @@
  trigger_error.
 
 
- The example below shows the handling of internal exceptions by 
- triggering errors and handling them with a user defined function. It then
- restores the original PHP error handling:
  
   
-   Error handling with set_error_handler,
-   trigger_error and 
-   restore_error_handler
+   Decide if unserialize caused an error, then
+   restore the original error handler.
   
   
 
   
-  &example.outputs.similar;
+  &example.outputs;
   
 
   
  


Re: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread David Mytton
Gabor Hojtsy wrote:
The output should be changed too :) It is not a good prectice to echo 
WARNING in case of a NOTICE, right? David's copy of this example should 
also be fixed. David?

Goba
All done :)
Regards,
David Mytton
Olate Ltd
http://www.olate.co.uk


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread David Mytton
dmytton Tue Apr  5 06:51:54 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
  Log:
  Fixed example switch statement output to show correct error types
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.7&r2=1.8&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.7 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.8
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.7   
Tue Apr  5 03:16:48 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Apr 
 5 06:51:53 2005
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -47,17 +47,17 @@
 {
 switch ($errno) {
 case E_USER_ERROR:
-echo "My FATAL [$errno] $errstr\n";
+echo "My ERROR [$errno] $errstr\n";
 echo "  Fatal error in line $errline of file $errfile";
 echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")\n";
 echo "Aborting...\n";
 exit(1);
 break;
 case E_USER_WARNING:
-echo "My ERROR [$errno] $errstr\n";
+echo "My WARNING [$errno] $errstr\n";
 break;
 case E_USER_NOTICE:
-echo "My WARNING [$errno] $errstr\n";
+echo "My NOTICE [$errno] $errstr\n";
 break;
 default:
 echo "My unkown error type: [$errno] $errstr\n";


Re: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread Gabor Hojtsy
+switch ($errno) {
+case E_USER_ERROR:
+echo "My FATAL [$errno] $errstr\n";
+echo "  Fatal error in line $errline of file $errfile";
+echo ", PHP " . PHP_VERSION . " (" . PHP_OS . ")\n";
+echo "Aborting...\n";
+exit(1);
+break;
+case E_USER_WARNING:
+echo "My ERROR [$errno] $errstr\n";
+break;
+case E_USER_NOTICE:
+echo "My WARNING [$errno] $errstr\n";
+break;
+default:
+echo "My unkown error type: [$errno] $errstr\n";
+break;
+}
The output should be changed too :) It is not a good prectice to echo 
WARNING in case of a NOTICE, right? David's copy of this example should 
also be fixed. David?

Goba


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread Jakub Vrana
vrana   Tue Apr  5 03:16:49 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
  Log:
  Remove confusing constants, fix WS
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.6&r2=1.7&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.6 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.7
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.6   
Mon Apr  4 14:00:21 2005
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Apr 
 5 03:16:48 2005
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -39,42 +39,37 @@
   
 
   


Re[2]: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-05 Thread anatoly techtonik
||*()*|| Hi, Gabor.

>> +// redefine the user error constants - PHP 4 only
>> +define("FATAL", E_USER_ERROR);
>> +define("ERROR", E_USER_WARNING);
>> +define("WARNING", E_USER_NOTICE);

GH> Is this from a different part of the manual? Is it supposed to be a good 
GH> idea to rename WARNING to ERROR and NOTICE to WARNING? It is becoming a 
GH> support nightmare then isn't it?

Definitely bad practive.

t
-- 


Re: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-04 Thread Gabor Hojtsy
+// redefine the user error constants - PHP 4 only
+define("FATAL", E_USER_ERROR);
+define("ERROR", E_USER_WARNING);
+define("WARNING", E_USER_NOTICE);
Is this from a different part of the manual? Is it supposed to be a 
good idea to rename WARNING to ERROR and NOTICE to WARNING? It is 
becoming a support nightmare then isn't it?
I just copied it from the set_error_handler docs and changed the code so 
it demonstrated the revert to previous handler function.
Yes, this was my suspicion... So I would like to hear others' opinions 
about the above confusing people (or not?).

Goba


Re: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-04 Thread David Mytton
Gabor Hojtsy wrote:
+// redefine the user error constants - PHP 4 only
+define("FATAL", E_USER_ERROR);
+define("ERROR", E_USER_WARNING);
+define("WARNING", E_USER_NOTICE);

Is this from a different part of the manual? Is it supposed to be a good 
idea to rename WARNING to ERROR and NOTICE to WARNING? It is becoming a 
support nightmare then isn't it?

Goba
I just copied it from the set_error_handler docs and changed the code so 
it demonstrated the revert to previous handler function.

David


Re: [PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-04 Thread Gabor Hojtsy
+// redefine the user error constants - PHP 4 only
+define("FATAL", E_USER_ERROR);
+define("ERROR", E_USER_WARNING);
+define("WARNING", E_USER_NOTICE);
Is this from a different part of the manual? Is it supposed to be a good 
idea to rename WARNING to ERROR and NOTICE to WARNING? It is becoming a 
support nightmare then isn't it?

Goba


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml

2005-04-04 Thread David Mytton
dmytton Mon Apr  4 14:00:22 2005 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
  Log:
  Added example
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.5&r2=1.6&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.5 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.6
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.5   
Tue Dec 14 06:53:48 2004
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Mon Apr 
 4 14:00:21 2005
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -26,6 +26,68 @@
  restore_exception_handler,
  trigger_error.
 
+
+ The example below shows the handling of internal exceptions by 
+ triggering errors and handling them with a user defined function. It then
+ restores the original PHP error handling:
+ 
+  
+   Error handling with set_error_handler,
+   trigger_error and 
+   restore_error_handler
+  
+  
+
+  
+  &example.outputs.similar;
+  
+
+  
+ 
+

   
 


[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml restore-exception-handler.xml

2004-12-14 Thread Derick Rethans
derick  Tue Dec 14 06:53:52 2004 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
restore-exception-handler.xml 
  Log:
  - Document return value.
  
  
http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml?r1=1.4&r2=1.5&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.4 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.5
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.4   
Mon Nov  1 11:31:23 2004
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Tue Dec 
14 06:53:48 2004
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -11,17 +11,19 @@

 &reftitle.description;
  
-  voidrestore_error_handler
+  boolrestore_error_handler
   
  
 
  Used after changing the error handler function using
  set_error_handler, to revert to the previous error
- handler (which could be the built-in or a user defined function)
+ handler (which could be the built-in or a user defined function). This
+ function always returns &true;.
 
 
  See also error_reporting,
  set_error_handler,
+ restore_exception_handler,
  trigger_error.
 

http://cvs.php.net/diff.php/phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml?r1=1.2&r2=1.3&ty=u
Index: phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml
diff -u 
phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.2 
phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.3
--- phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml:1.2   
Mon Nov  1 11:31:24 2004
+++ phpdoc/en/reference/errorfunc/functions/restore-exception-handler.xml   
Tue Dec 14 06:53:48 2004
@@ -1,5 +1,5 @@
 
-
+
   

 restore_exception_handler
@@ -10,19 +10,20 @@

 &reftitle.description;
  
-  voidrestore_exception_handler
+  boolrestore_exception_handler
   
  
 
  Used after changing the exception handler function using
  set_exception_handler, to revert to the previous 
  exception handler (which could be the built-in or a user defined 
- function)
+ function). This function always returns &true;.
 
 
  See also
  set_exception_handler,
- set_error_handler, and 
+ set_error_handler,
+ restore_error_handler
  error_reporting
 



[PHP-DOC] cvs: phpdoc /en/reference/errorfunc/functions restore-error-handler.xml set-error-handler.xml trigger-error.xml

2003-12-01 Thread Friedhelm Betz
betzMon Dec  1 06:46:50 2003 EDT

  Modified files:  
/phpdoc/en/reference/errorfunc/functionsrestore-error-handler.xml 
set-error-handler.xml 
trigger-error.xml 
  Log:
  remove user_error from see also
  added link to error constants in see also
  
  
Index: phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.2 
phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.3
--- phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml:1.2   Wed 
Apr 17 02:37:45 2002
+++ phpdoc/en/reference/errorfunc/functions/restore-error-handler.xml   Mon Dec  1 
06:46:50 2003
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -22,7 +22,7 @@
 
  See also error_reporting,
  set_error_handler,
- trigger_error, user_error
+ trigger_error.
 

   
Index: phpdoc/en/reference/errorfunc/functions/set-error-handler.xml
diff -u phpdoc/en/reference/errorfunc/functions/set-error-handler.xml:1.14 
phpdoc/en/reference/errorfunc/functions/set-error-handler.xml:1.15
--- phpdoc/en/reference/errorfunc/functions/set-error-handler.xml:1.14  Sat Aug 16 
14:59:11 2003
+++ phpdoc/en/reference/errorfunc/functions/set-error-handler.xml   Mon Dec  1 
06:46:50 2003
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -200,7 +200,8 @@
 
  See also error_reporting,
  restore_error_handler,
- trigger_error, user_error
+ trigger_error, and
+ error level constants.
 

   
Index: phpdoc/en/reference/errorfunc/functions/trigger-error.xml
diff -u phpdoc/en/reference/errorfunc/functions/trigger-error.xml:1.6 
phpdoc/en/reference/errorfunc/functions/trigger-error.xml:1.7
--- phpdoc/en/reference/errorfunc/functions/trigger-error.xml:1.6   Sat Aug 16 
14:59:11 2003
+++ phpdoc/en/reference/errorfunc/functions/trigger-error.xml   Mon Dec  1 06:46:50 
2003
@@ -1,5 +1,5 @@
 
-
+
 
   

@@ -53,7 +53,7 @@
  See also error_reporting,
  set_error_handler,
  restore_error_handler, and
- user_error.
+ error level constants.