X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=plugins%2Finfo%2Ffunctions.php;h=36bff635d67d386368d1e2987b4f2404dedef69f;hp=95c779cf6b42e859891ccc16512ad00d091febe9;hb=47ccfad452e8d345542d09e59112cac317cffed8;hpb=ea5f4b8eaf805c4cc4e9533e87d057300a7fe666 diff --git a/plugins/info/functions.php b/plugins/info/functions.php index 95c779cf..36bff635 100644 --- a/plugins/info/functions.php +++ b/plugins/info/functions.php @@ -1,25 +1,28 @@ - + * @copyright © 1999-2006 The SquirrelMail Project Team + * @license http://opensource.org/licenses/gpl-license.php GNU Public License + * @version $Id$ * @package plugins * @subpackage info */ /** * Get the IMAP capabilities + * + * @param mixed $imap_stream * @return array + * @access private */ function get_caps($imap_stream) { return sqimap_run_command_list($imap_stream, 'CAPABILITY',false, $responses, $message,false); @@ -27,11 +30,14 @@ function get_caps($imap_stream) { /** * Run an IMAP test and return the results + * + * @param mixed $imap_stream + * @param string $string imap command * @return array Response from the IMAP server + * @access private */ function imap_test($imap_stream, $string) { - global $default_charset; - print "".$string.""; + print "".htmlspecialchars($string).""; $response = sqimap_run_command_list($imap_stream, trim($string),false, $responses, $message,false); array_push($response, $responses . ' ' .$message); return $response; @@ -39,6 +45,9 @@ function imap_test($imap_stream, $string) { /** * Print the IMAP response to options.php + * + * @param array $response results of imap command + * @access private */ function print_response($response) { foreach($response as $index=>$value) { @@ -46,11 +55,9 @@ function print_response($response) { print_response($value); } else { - $value = preg_replace("//", ">", $value); - print $value."
\n"; + print htmlspecialchars($value)."
\n"; } } } - -?> + +?> \ No newline at end of file