Ignore:
Timestamp:
2008/10/27 17:32:16 (15 years ago)
Author:
takegami
Message:

#353 文字コードのエンコードを回収

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2/data/class/helper/SC_Helper_Mobile.php

    r17119 r17659  
    5656     */ 
    5757    function lfMobileConvertInputValue(&$value) { 
    58         // Shift JIS から内部エンコーディングに変換する。 
    59         // SoftBank 以外の絵文字は外字領域に含まれるため、この段階で除去される。 
    60         $value = mb_convert_encoding($value, CHAR_CODE, 'SJIS'); 
    61  
    62         // SoftBank の絵文字を除去する。 
    63         $value = preg_replace('/\\x1b\\$[^\\x0f]*\\x0f/', '', $value); 
     58        if (is_array($value)) { 
     59            foreach($value as $key => $val ){ 
     60                $this->lfMobileConvertInputValue($value[$key]); 
     61            } 
     62        } else { 
     63            // Shift JIS から内部エンコーディングに変換する。 
     64            $value = mb_convert_encoding($value, CHAR_CODE, 'SJIS'); 
     65            // SoftBank? 以外の絵文字は外字領域に含まれるため、この段階で除去される。 
     66            // SoftBank? の絵文字を除去する。 
     67            $value = preg_replace('/\\x1b\\$[^\\x0f]*\\x0f/', '', $value); 
     68        } 
    6469    } 
    6570 
Note: See TracChangeset for help on using the changeset viewer.