recursive print to file


/ Published in: PHP
Save to your folder(s)

Print array/object to file


Copy this code and paste it in your HTML
  1. $output = print_r($array, true);
  2. $fp = fopen("/path/to/textfile.txt", "w");
  3. fwrite($fp, $output);
  4. fclose($fp);

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.