Ignore:
Timestamp:
2010/06/10 16:44:24 (12 years ago)
Author:
nanasess
bzr:base-revision:
ohkouchi@loop-az.jp-20100610073302-8e245zm42vq398b4
bzr:committer:
Kentaro Ohkouchi <ohkouchi@loop-az.jp>
bzr:file-ids:

data/class/helper/SC_Helper_CSV.php 15535@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fhelper%2FSC_Helper_CSV.php
data/class/pages/admin/system/LC_Page_Admin_System_Bkup.php 16251@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Fpages%2Fadmin%2Fsystem%2FLC_Page_Admin_System_Bkup.php
data/class/util/SC_Utils.php 15078@1e3b908f-19a9-db11-a64c-001125224ba8:branches%2Ffeature-module-update%2Fdata%2Fclass%2Futil%2FSC_Utils.php
bzr:mapping-version:
v4
bzr:repository-uuid:
1e3b908f-19a9-db11-a64c-001125224ba8
bzr:revision-id:
ohkouchi@loop-az.jp-20100610074421-i3dwjk10nnz0lsqm
bzr:revno:
1959
bzr:revprop:branch-nick:
branches/version-2_4-dev
bzr:root:
branches/version-2_4-dev
bzr:text-parents:

data/class/helper/SC_Helper_CSV.php ohkouchi@loop-az.jp-20100607063506-7aygam8pu7925183
data/class/pages/admin/system/LC_Page_Admin_System_Bkup.php ohkouchi@loop-az.jp-20100607063506-7aygam8pu7925183
data/class/util/SC_Utils.php ohkouchi@loop-az.jp-20100607113809-a2ooznl16n2ko77e
bzr:timestamp:
2010-06-10 16:44:21.206000090 +0900
bzr:user-agent:
bzr2.1.1+bzr-svn1.0.2
svn:original-date:
2010-06-10T07:44:21.206000Z
Message:

CSVダウンロードで"が入っているときのエスケープ処理を修正(#755)

Location:
branches/version-2_4-dev/data/class
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • branches/version-2_4-dev/data/class/helper/SC_Helper_CSV.php

    r18674 r18685  
    266266                break; 
    267267            } 
    268  
    269             $tmp = ereg_replace("[\",]", " ", $tmp); 
     268            $tmp = ereg_replace("\"", "\"\"", $tmp); 
    270269            $line .= "\"".$tmp."\","; 
    271270        } 
     
    297296            } 
    298297 
    299             $tmp = ereg_replace("[\",]", " ", $tmp); 
     298            $tmp = ereg_replace("\"", "\"\"", $tmp); 
    300299            $line .= "\"".$tmp."\","; 
    301300        } 
     
    320319            } 
    321320 
    322             $tmp = ereg_replace("[\",]", " ", $tmp); 
     321            $tmp = ereg_replace("\"", "\"\"", $tmp); 
    323322            $line .= "\"".$tmp."\","; 
    324323        } 
  • branches/version-2_4-dev/data/class/pages/admin/system/LC_Page_Admin_System_Bkup.php

    r18674 r18685  
    240240                    $data = ""; 
    241241                    foreach($arrData as $data_key => $data_val){ 
    242                         //$val = str_replace("\"", "\\\"", $val); 
    243242                        $data .= $this->lfGetCSVList($arrData[$data_key]); 
    244243 
     
    343342            foreach($array as $key => $val) { 
    344343                $val = mb_convert_encoding($val, CHAR_CODE, CHAR_CODE); 
    345                 $val = str_replace("\"", "\\\"", $val); 
     344                $val = str_replace("\"", "\"\"", $val); 
    346345                $line .= "\"".$val."\","; 
    347346            } 
     
    591590            } 
    592591            $sql .= " );"; 
    593             $data = str_replace("\\\"", "\"", $data); 
    594592            $err = $objQuery->query($sql, $data); 
    595593 
  • branches/version-2_4-dev/data/class/util/SC_Utils.php

    r18676 r18685  
    560560            foreach($array as $key => $val) { 
    561561                $val = mb_convert_encoding($val, CHAR_CODE, CHAR_CODE); 
     562                $val = ereg_replace("\"", "\"\"", $val); 
    562563                $line .= "\"".$val."\","; 
    563564            } 
Note: See TracChangeset for help on using the changeset viewer.