Tag Archives: Ivan Kristianto

PHP – Write an Array/Object to File by print_r()

In debugging PHP program, i always use print() and print_r() to output the variable content to the browser. But this does not work when we are not using browser. A simple way to get the content is to write it to a file.

I found a nice post written by Ivan which provides this simple way with just a few lines of code.
Ivan Kristianto – [TIPS] Write print_r() Output To File Continue reading PHP – Write an Array/Object to File by print_r()