", $message); $message = str_replace(" ", " ", $message); global $_ERRORS; $_ERRORS[] = $message; } /** * Write text into stderr * * @param string $text Text to log */ function debug ($text) { error_log("\n> $text" . PHP_EOL); } /** * Echoes HTML code to display all collected error messages */ function insertErrorsHtml() { global $_ERRORS; if (count ($_ERRORS) == 0) return; // Dialog frame HTML $base_html = '