X-Git-Url: https://vcs.fsf.org/?p=squirrelmail.git;a=blobdiff_plain;f=plugins%2Ffilters%2Foptions.php;h=ee65e38d78264fbb331bb0b6d120cbba20c0c319;hp=222ca7493d071f7c1e66fb35c080b0a56f03d095;hb=353d074afac6827c90f4bb03e846c5e453d3b5b1;hpb=202bcbcc2b67c7c153db1b09b608b62beeba0496 diff --git a/plugins/filters/options.php b/plugins/filters/options.php index 222ca749..ee65e38d 100644 --- a/plugins/filters/options.php +++ b/plugins/filters/options.php @@ -3,7 +3,7 @@ /** * Message and Spam Filter Plugin - Filtering Options * - * @copyright © 1999-2006 The SquirrelMail Project Team + * @copyright 1999-2018 The SquirrelMail Project Team * @license http://opensource.org/licenses/gpl-license.php GNU Public License * @version $Id$ * @package plugins @@ -15,18 +15,17 @@ */ require('../../include/init.php'); include_once(SM_PATH . 'functions/imap_general.php'); +include_once(SM_PATH . 'functions/forms.php'); include_once(SM_PATH . 'plugins/filters/filters.php'); -displayPageHeader($color, 'None'); +displayPageHeader($color); /* get globals */ -sqgetGlobalVar('username', $username, SQ_SESSION); -sqgetGlobalVar('key', $key, SQ_COOKIE); -sqgetGlobalVar('onetimepad', $onetimepad, SQ_SESSION); sqgetGlobalVar('delimiter', $delimiter, SQ_SESSION); sqgetGlobalVar('theid', $theid); sqgetGlobalVar('action', $action, SQ_GET); +global $imap_stream_options; // in case not defined in config if (sqgetGlobalVar('filter_submit',$filter_submit,SQ_POST)) { @@ -54,7 +53,7 @@ if (sqgetGlobalVar('filter_submit',$filter_submit,SQ_POST)) { } if ($complete_post) { - $filter_what = str_replace(',', ' ', $filter_what); + $filter_what = str_replace(',', '###COMMA###', $filter_what); $filter_what = str_replace("\\\\", "\\", $filter_what); $filter_what = str_replace("\\\"", '"', $filter_what); $filter_what = str_replace('"', '"', $filter_what); @@ -127,7 +126,7 @@ if (sqgetGlobalVar('filter_submit',$filter_submit,SQ_POST)) { if (isset($action) && ($action == 'add' || $action == 'edit')) { - $imapConnection = sqimap_login($username, $key, $imapServerAddress, $imapPort, 0); + $imapConnection = sqimap_login($username, false, $imapServerAddress, $imapPort, 0, $imap_stream_options); $boxes = sqimap_mailbox_list($imapConnection); for ($a = 0, $cnt = count($boxes); $a < $cnt; $a++) { @@ -182,7 +181,7 @@ if (sqgetGlobalVar('filter_submit',$filter_submit,SQ_POST)) { html_tag( 'td', '', 'left' ) . ''. ''. @@ -245,7 +244,7 @@ if (count($filters)) { printf( _("If %s contains %s then move to %s"), ''.$filters[$i]['where'].'', ''.$filters[$i]['what'].'', - ''.imap_utf7_decode_local($fdr).''); + ''.sm_encode_html_special_chars(imap_utf7_decode_local($fdr)).''); echo ''; } @@ -257,4 +256,3 @@ if (count($filters)) { ) , 'center', '', 'width="80%" border="0" cellpadding="2" cellspacing="0"' ); echo ''; -?> \ No newline at end of file