codes****@googl*****
codes****@googl*****
2009年 3月 14日 (土) 18:21:33 JST
Author: tacahi Date: Sat Mar 14 02:09:28 2009 New Revision: 1263 Modified: branches/geeklog-1.5.1-jp-extended/system/custom/custom_mail_jp.php (contents, props changed) Log: r1242の変更を反映します。 r1242: r1216の更新をgeeklog-1-jp-extendedにも適用します。 Modified: branches/geeklog-1.5.1-jp-extended/system/custom/custom_mail_jp.php ============================================================================== --- branches/geeklog-1.5.1-jp-extended/system/custom/custom_mail_jp.php (original) +++ branches/geeklog-1.5.1-jp-extended/system/custom/custom_mail_jp.php Sat Mar 14 02:09:28 2009 @@ -11,7 +11,7 @@ // メールに戻します。 // @author mystral-kk - geeklog AT mystral-kk DOT net // @license LGPL -// @version 2008-09-26 +// @version 2009-02-27 // @note このハックが不要な場合は,system/lib-custom.phpの中の // require_once('custom/custom_mail_jp.php'); // を削除してください。 @@ -261,14 +261,16 @@ $from = COM_formatEmailAddress($_CONF['site_name'], $_CONF['site_mail']); } - // ヘッダをエスケープ - list($temp_to_comment, $temp_to_address) = CUSTOM_splitAddress($to); - $to = CUSTOM_formatEmailAddress($temp_to_comment, $temp_to_address); - list($temp_cc_comment, $temp_cc_address) = CUSTOM_splitAddress($cc); - $cc = CUSTOM_formatEmailAddress($temp_cc_comment, $temp_cc_address); - list($temp_from_comment, $temp_from_address) = CUSTOM_splitAddress($from); - $from = CUSTOM_formatEmailAddress($temp_from_comment, $temp_from_address); - $subject = CUSTOM_emailEscape($subject); + // ヘッダをエスケープ(1.5.2では、この時点でエスケープ済み) + if (version_compare(VERSION, '1.5.2') < 0) { + list($temp_to_comment, $temp_to_address) = CUSTOM_splitAddress($to); + $to = CUSTOM_formatEmailAddress($temp_to_comment, $temp_to_address); + list($temp_cc_comment, $temp_cc_address) = CUSTOM_splitAddress($cc); + $cc = CUSTOM_formatEmailAddress($temp_cc_comment, $temp_cc_address); + list($temp_from_comment, $temp_from_address) = CUSTOM_splitAddress($from); + $from = CUSTOM_formatEmailAddress($temp_from_comment, $temp_from_address); + $subject = CUSTOM_emailEscape($subject); + } // 本文をエスケープ $message = CUSTOM_convertEncoding($message, CUSTOM_MAIL_ENCODING);