Skip to content

Commit

Permalink
Use var_export instead of print_r for better clarity.
Browse files Browse the repository at this point in the history
  • Loading branch information
bharat committed Jan 29, 2010
1 parent d4998e3 commit a956098
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions modules/rest/helpers/rest.php
Expand Up @@ -25,8 +25,8 @@ static function reply($data=array()) {
if (Input::instance()->get("output") == "html") {
header("Content-type: text/html");
$html = preg_replace(
"#(^|[\n ])([\w]+?://[\w]+[^ \"\n\r\t<]*)#ise", "'\\1<a href=\"\\2\" >\\2</a>'",
print_r($data, 1));
"#([\w]+?://[\w]+[^ \'\"\n\r\t<]*)#ise", "'<a href=\"\\1\" >\\1</a>'",
var_export($data, 1));
print "<pre>$html</pre>";
} else {
header("Content-type: application/json");
Expand Down

0 comments on commit a956098

Please sign in to comment.