From 06ddaedaa98e5ad18bd0a24dcf1313d7f4d2465b Mon Sep 17 00:00:00 2001 From: Leandro Lucarella Date: Mon, 29 Mar 2004 18:58:38 +0000 Subject: [PATCH] =?utf8?q?Se=20agrega=20el=20m=C3=A9todo=20dump=20que=20us?= =?utf8?q?a=20Var=5FDump=20de=20PEAR.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- lib/MECON/HTML/Page.php | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/lib/MECON/HTML/Page.php b/lib/MECON/HTML/Page.php index aaac822..c50bf21 100644 --- a/lib/MECON/HTML/Page.php +++ b/lib/MECON/HTML/Page.php @@ -87,5 +87,21 @@ class MECON_HTML_Page extends HTML_Page { exit; } + /** + * Muestra una variable para debug. + */ + function dump($var, $exit = false) + { + if (!isset($this->_dump)) { + require_once 'Var_Dump.php'; + $this->_dump = new Var_Dump( + array('displayMode' => VAR_DUMP_DISPLAY_MODE_HTML_TABLE)); + } + $this->addBodyContent('
');
+        $this->addBodyContent($this->_dump->r_display($var));
+        $this->addBodyContent('
'); + if ($exit) exit; + } + } ?> \ No newline at end of file -- 2.43.0