print_r return BLANK PAGE

夙愿已清 提交于 2019-12-11 09:07:59

问题


I have a weird problem, I am using print_r($obj) in Joomla YOOtheme ZOO extension and it returns a blank page. it just act as die() !

it should output the object but it does not.

Please note that print_r() is working fine with some other objects and variables.

I am using XAMPP on Windows.

Any help?

Upon executing print_r() and var_dump(), the page is just blank, no error, view source shows:

<html>
  <head></head>
  <body></body>
</html>

Error reporting is turned on.


回答1:


It is posible that $obj is too big to load, and grabs a lot of memory after which the script stops to work.

Thanks




回答2:


Is error reporting turned on?

If not add to your code:

ini_set("display_errors", "1");




回答3:


If it's outputting nothing, $obj contains nothing. Try var_dump() instead. Also, make sure you're seeing all errors that PHP is producing:

ini_set('display_errors', 1);
error_reporting(-1);


来源:https://stackoverflow.com/questions/8957150/print-r-return-blank-page

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!