]> git.mxchange.org Git - quix0rs-gnu-social.git/blobdiff - extlib/PEAR/Exception.php
Merge branch 'master' into testing
[quix0rs-gnu-social.git] / extlib / PEAR / Exception.php
index b3d75b20c9cfe886530994469f0275d059ab665a..d0327b141b432daea538dfdac9b06c6f9899ab3d 100644 (file)
@@ -5,21 +5,15 @@
  *
  * PHP versions 4 and 5
  *
- * LICENSE: This source file is subject to version 3.0 of the PHP license
- * that is available through the world-wide-web at the following URI:
- * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
- * the PHP License and are unable to obtain it through the web, please
- * send a note to license@php.net so we can mail you a copy immediately.
- *
  * @category   pear
  * @package    PEAR
  * @author     Tomas V. V. Cox <cox@idecnet.com>
  * @author     Hans Lellelid <hans@velum.net>
  * @author     Bertrand Mansion <bmansion@mamasam.com>
  * @author     Greg Beaver <cellog@php.net>
- * @copyright  1997-2008 The PHP Group
- * @license    http://www.php.net/license/3_0.txt  PHP License 3.0
- * @version    CVS: $Id: Exception.php,v 1.29 2008/01/03 20:26:35 cellog Exp $
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Exception.php 307683 2011-01-23 21:56:12Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.3.3
  */
@@ -93,9 +87,9 @@
  * @author     Hans Lellelid <hans@velum.net>
  * @author     Bertrand Mansion <bmansion@mamasam.com>
  * @author     Greg Beaver <cellog@php.net>
- * @copyright  1997-2008 The PHP Group
- * @license    http://www.php.net/license/3_0.txt  PHP License 3.0
- * @version    Release: 1.7.2
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.2
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.3.3
  *
@@ -295,7 +289,7 @@ class PEAR_Exception extends Exception
     }
 
     public function getTraceSafe()
-    {   
+    {
         if (!isset($this->_trace)) {
             $this->_trace = $this->getTrace();
             if (empty($this->_trace)) {
@@ -331,21 +325,21 @@ class PEAR_Exception extends Exception
         $trace = $this->getTraceSafe();
         $causes = array();
         $this->getCauseMessage($causes);
-        $html =  '<table border="1" cellspacing="0">' . "\n";
+        $html =  '<table style="border: 1px" cellspacing="0">' . "\n";
         foreach ($causes as $i => $cause) {
-            $html .= '<tr><td colspan="3" bgcolor="#ff9999">'
+            $html .= '<tr><td colspan="3" style="background: #ff9999">'
                . str_repeat('-', $i) . ' <b>' . $cause['class'] . '</b>: '
                . htmlspecialchars($cause['message']) . ' in <b>' . $cause['file'] . '</b> '
                . 'on line <b>' . $cause['line'] . '</b>'
                . "</td></tr>\n";
         }
-        $html .= '<tr><td colspan="3" bgcolor="#aaaaaa" align="center"><b>Exception trace</b></td></tr>' . "\n"
-               . '<tr><td align="center" bgcolor="#cccccc" width="20"><b>#</b></td>'
-               . '<td align="center" bgcolor="#cccccc"><b>Function</b></td>'
-               . '<td align="center" bgcolor="#cccccc"><b>Location</b></td></tr>' . "\n";
+        $html .= '<tr><td colspan="3" style="background-color: #aaaaaa; text-align: center; font-weight: bold;">Exception trace</td></tr>' . "\n"
+               . '<tr><td style="text-align: center; background: #cccccc; width:20px; font-weight: bold;">#</td>'
+               . '<td style="text-align: center; background: #cccccc; font-weight: bold;">Function</td>'
+               . '<td style="text-align: center; background: #cccccc; font-weight: bold;">Location</td></tr>' . "\n";
 
         foreach ($trace as $k => $v) {
-            $html .= '<tr><td align="center">' . $k . '</td>'
+            $html .= '<tr><td style="text-align: center;">' . $k . '</td>'
                    . '<td>';
             if (!empty($v['class'])) {
                 $html .= $v['class'] . $v['type'];
@@ -373,7 +367,7 @@ class PEAR_Exception extends Exception
                    . ':' . (isset($v['line']) ? $v['line'] : 'unknown')
                    . '</td></tr>' . "\n";
         }
-        $html .= '<tr><td align="center">' . ($k+1) . '</td>'
+        $html .= '<tr><td style="text-align: center;">' . ($k+1) . '</td>'
                . '<td>{main}</td>'
                . '<td>&nbsp;</td></tr>' . "\n"
                . '</table>';
@@ -392,6 +386,4 @@ class PEAR_Exception extends Exception
         }
         return $causeMsg . $this->getTraceAsString();
     }
-}
-
-?>
\ No newline at end of file
+}
\ No newline at end of file