Changeset 17927


Ignore:
Timestamp:
2009/03/25 16:18:11 (15 years ago)
Author:
Seasoft
Message:

モバイルの会員登録でメールマガジンを配信希望とするとDBエラーが発生する問題を修正。
フォーラムにてyakitori様の報告。 http://xoops.ec-cube.net/modules/newbb/viewtopic.php?topic_id=3662&forum=8

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/comu-ver2/data/class/pages/mypage/LC_Page_Mypage_Change.php

    r17891 r17927  
    353353                    $passlen = strlen($this->arrForm['password']); 
    354354                    $this->passlen = $this->lfPassLen($passlen); 
    355  
    356                     // メール受け取り 
    357                     if (!isset($_POST['mailmaga_flg'])) $_POST['mailmaga_flg'] = ""; 
    358                     if (strtolower($_POST['mailmaga_flg']) == "on") { 
    359                         $_POST['mailmaga_flg']  = "2"; 
    360                     } else { 
    361                         $_POST['mailmaga_flg']  = "3"; 
    362                     } 
    363355 
    364356                    $this->tpl_mainpage = 'mypage/change_confirm.tpl'; 
     
    535527         *  a :  全角英数字を半角英数字に変換する 
    536528         */ 
    537         // カラム名とコンバート情報 
    538         foreach ($arrRegistColumn as $data) { 
    539             $arrConvList[ $data["column"] ] = $data["convert"]; 
    540         } 
    541  
    542         // 文字変換 
    543         foreach ($arrConvList as $key => $val) { 
    544             // POSTされてきた値のみ変換する。 
    545             if (isset($array[$key])) { 
    546                 if(strlen(($array[$key])) > 0) { 
    547                     $array[$key] = mb_convert_kana($array[$key] ,$val); 
     529 
     530        foreach ($arrRegistColumn as $registColumn) { 
     531            $key = $registColumn["column"]; 
     532            $mb_convert_kana_option = $registColumn["convert"]; 
     533            $val =& $array[$key]; 
     534             
     535            // 文字変換 
     536            // XXX 文字列のみを変換するようにした方が良い気もする。 
     537            if (strlen($val) > 0) { 
     538                $val = mb_convert_kana($val ,$mb_convert_kana_option); 
     539            } 
     540             
     541            // メールマガジン 
     542            if ($key == 'mailmaga_flg') { 
     543                if (strtolower($val) == "on") { 
     544                    $val = "2"; 
     545                } else if ($val != "2") { 
     546                    $val = "3"; 
    548547                } 
    549548            } 
Note: See TracChangeset for help on using the changeset viewer.