From 1a46d86ca6cadb4bfd6e894a1108ebea013a9ef9 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Mon, 11 Jan 2016 19:52:54 +0100 Subject: [PATCH] lib/util.php quick function to do var_export($var,true) Immensely useful when debugging and we want to put quotes around strings, potentially stopping any "evil logging attacks" (where input data masks as logging data). --- lib/util.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/util.php b/lib/util.php index 7ebbf42cf6..1d973d7100 100644 --- a/lib/util.php +++ b/lib/util.php @@ -2454,3 +2454,8 @@ function html_sprintf() } return call_user_func_array('sprintf', $args); } + +function _ve($var) +{ + return var_export($var, true); +} -- 2.39.5