Last active
October 17, 2022 05:55
-
-
Save erowsika/e04cd538566d7182ccd215749b79c18e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
function e($value, $doubleEncode = true) { | |
return htmlspecialchars($value ?? '', ENT_QUOTES, 'UTF-8', $doubleEncode); | |
} | |
function dd($var) { | |
$backTrace = debug_backtrace(); | |
$file = $backTrace[0]['file']; | |
$line = $backTrace[0]['line']; | |
echo "<pre class='pretty-print'>Line $line in <br>$file: <br><br>"; | |
var_dump($var); | |
echo "</pre>"; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment