kwandoa Posted April 24, 2013 Share Posted April 24, 2013 Hi I would like clarification on when to use echo and when to use print_r(). Also the 2 aurguments print_r() takes. I understand the variable $students but not the 1 in <? print_r($students, 1); ?> Link to comment Share on other sites More sharing options...
HartleySan Posted April 24, 2013 Share Posted April 24, 2013 echo is for standard output. print_r is more for printing out variable info for debugging and whatnot. Please see the following explanation of print_r: http://php.net/manual/en/function.print-r.php Link to comment Share on other sites More sharing options...
Recommended Posts