website/libraries/console.php

10 lines
206 B
PHP

<?php
function console_log($data) {
$output = $data;
if (is_array($output))
$output = implode(',', $output);
echo "<script>console.log('Debug Objects: " . $output . "' );</script>";
}