1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
<?php include("./_common.php");
//echo "막혓음";exit;
for($x=0;$x<4;$x++){
//if($x>0){ continue; }
$info_array = null;
$sql = "select * from xls_reader where xls_file = '{$x}' and xls_content <> '' order by xls_no, xls_alpha "; $res = mysql_query($sql,$connect_j3);
while($info=mysql_fetch_array($res)){ $info_array[] = $info; }
$cnt=0; $update_cnt = 0; foreach($info_array as $key=>$info){ $xc = $info['xls_content']; if(preg_match("/[\xE0-\xFF][\x80-\xFF][\x80-\xFF]/", $xc)){ // 한글 있음 $info['xls_content'] = addslashes($info['xls_content']); $sql = "update xls_reader set xls_left = '{$info['xls_content']}' where idx = '{$info['idx']}' "; mysql_query($sql,$connect_j3); $update_cnt++; } else { // 한글 없음 } $cnt++; }
_pr("총 단어 : {$cnt}"); _pr("남긴 단어 : {$update_cnt}"); }
?>
|