From a95609849e42656b35f0110a08cc4436ad56b916 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Fri, 29 Jan 2010 14:53:40 -0800 Subject: Use var_export instead of print_r for better clarity. --- modules/rest/helpers/rest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/rest/helpers') diff --git a/modules/rest/helpers/rest.php b/modules/rest/helpers/rest.php index 0d2ec9d4..1f95a7e7 100644 --- a/modules/rest/helpers/rest.php +++ b/modules/rest/helpers/rest.php @@ -25,8 +25,8 @@ class rest_Core { if (Input::instance()->get("output") == "html") { header("Content-type: text/html"); $html = preg_replace( - "#(^|[\n ])([\w]+?://[\w]+[^ \"\n\r\t<]*)#ise", "'\\1\\2'", - print_r($data, 1)); + "#([\w]+?://[\w]+[^ \'\"\n\r\t<]*)#ise", "'\\1'", + var_export($data, 1)); print "
$html
"; } else { header("Content-type: application/json"); -- cgit v1.2.3