From bfbc90aa8f790ec7f7a183b910f275541c094725 Mon Sep 17 00:00:00 2001 From: Evgeny Gryaznov Date: Wed, 16 Feb 2011 01:40:39 +0100 Subject: [PATCH] fix captcha --- src/messenger/webim/captcha.php | 2 +- src/messenger/webim/leavemessage.php | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/messenger/webim/captcha.php b/src/messenger/webim/captcha.php index b260775e..f17ab5c8 100644 --- a/src/messenger/webim/captcha.php +++ b/src/messenger/webim/captcha.php @@ -23,7 +23,7 @@ require_once('libs/common.php'); require_once('libs/captcha.php'); $captchaCode = gen_captcha(); -$_SESSION["captcha"] = $captchaCode; +$_SESSION["mibew_captcha"] = $captchaCode; draw_captcha($captchaCode); exit; diff --git a/src/messenger/webim/leavemessage.php b/src/messenger/webim/leavemessage.php index b5363306..e891fd17 100644 --- a/src/messenger/webim/leavemessage.php +++ b/src/messenger/webim/leavemessage.php @@ -83,11 +83,11 @@ if( !$email ) { if($settings["enablecaptcha"] == "1" && can_show_captcha()) { $captcha = getparam('captcha'); - $original = isset($_SESSION['captcha']) ? $_SESSION['captcha'] : ""; + $original = isset($_SESSION["mibew_captcha"]) ? $_SESSION["mibew_captcha"] : ""; if(empty($original) || empty($captcha) || $captcha != $original) { $errors[] = getlocal('errors.captcha'); } - unset($_SESSION['captcha']); + unset($_SESSION['mibew_captcha']); } if( count($errors) > 0 ) {