<?
include_once("./_common.php");
/* 기존의 DB에서 불러오는 방식
if ($addr1)
{
$zipfile = file("./zip.db");
$search_count = 0;
while ($zipcode = each($zipfile))
{
if(strstr(substr($zipcode[1],9,512), $addr1))
{
$list[$search_count][zip1] = substr($zipcode[1],0,3);
$list[$search_count][zip2] = substr($zipcode[1],4,3);
$addr = explode(" ", substr($zipcode[1],8));
if ($addr[sizeof($addr)-1])
{
$list[$search_count][addr] = str_replace($addr[sizeof($addr)-1], "", substr($zipcode[1],8));
$list[$search_count][bunji] = trim($addr[sizeof($addr)-1]);
}
else
$list[$search_count][addr] = substr($zipcode[1],8);
$list[$search_count][encode_addr] = urlencode($list[$search_count][addr]);
$search_count++;
}
}
if (!$search_count) alert("찾으시는 주소가 없습니다.");
}
*/
if ($addr1)
{
//$sql = " select * from zipcode where zp_dong like '%$addr1%' order by zp_sido, zp_gugun, zp_dong ";
$sql = " select * from $g4[zipcode] where zp_dong like '%$addr1%' order by zp_sido, zp_gugun, zp_dong ";
echo $sql;
//echo '<xmp>';
//print_r($g4);
//echo '</xmp>';
$result = mysql_query($sql);
$search_count = 0;
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$list[$i][zip1] = substr($row[zp_code], 0, 3);
$list[$i][zip2] = substr($row[zp_code], 3, 3);
$list[$i][addr] = "$row[zp_sido] $row[zp_gugun] $row[zp_dong]";
$list[$i][bunji] = $row[zp_bunji];
$list[$i][encode_addr] = urlencode($list[$i][addr1]);
$search_count++;
}
if (!$search_count)
alert("찾으시는 주소가 없습니다.");
}
$g4[title] = "우편번호 검색";
include_once("$g4[path]/ahead.sub.php");
$member_skin_path = "$g4[path]/skin/member/$config[cf_member_skin]";
include_once("$member_skin_path/zip.skin.php");
include_once("$g4[path]/tail.sub.php");
?>
include_once("./_common.php");
/* 기존의 DB에서 불러오는 방식
if ($addr1)
{
$zipfile = file("./zip.db");
$search_count = 0;
while ($zipcode = each($zipfile))
{
if(strstr(substr($zipcode[1],9,512), $addr1))
{
$list[$search_count][zip1] = substr($zipcode[1],0,3);
$list[$search_count][zip2] = substr($zipcode[1],4,3);
$addr = explode(" ", substr($zipcode[1],8));
if ($addr[sizeof($addr)-1])
{
$list[$search_count][addr] = str_replace($addr[sizeof($addr)-1], "", substr($zipcode[1],8));
$list[$search_count][bunji] = trim($addr[sizeof($addr)-1]);
}
else
$list[$search_count][addr] = substr($zipcode[1],8);
$list[$search_count][encode_addr] = urlencode($list[$search_count][addr]);
$search_count++;
}
}
if (!$search_count) alert("찾으시는 주소가 없습니다.");
}
*/
if ($addr1)
{
//$sql = " select * from zipcode where zp_dong like '%$addr1%' order by zp_sido, zp_gugun, zp_dong ";
$sql = " select * from $g4[zipcode] where zp_dong like '%$addr1%' order by zp_sido, zp_gugun, zp_dong ";
echo $sql;
//echo '<xmp>';
//print_r($g4);
//echo '</xmp>';
$result = mysql_query($sql);
$search_count = 0;
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$list[$i][zip1] = substr($row[zp_code], 0, 3);
$list[$i][zip2] = substr($row[zp_code], 3, 3);
$list[$i][addr] = "$row[zp_sido] $row[zp_gugun] $row[zp_dong]";
$list[$i][bunji] = $row[zp_bunji];
$list[$i][encode_addr] = urlencode($list[$i][addr1]);
$search_count++;
}
if (!$search_count)
alert("찾으시는 주소가 없습니다.");
}
$g4[title] = "우편번호 검색";
include_once("$g4[path]/ahead.sub.php");
$member_skin_path = "$g4[path]/skin/member/$config[cf_member_skin]";
include_once("$member_skin_path/zip.skin.php");
include_once("$g4[path]/tail.sub.php");
?>
댓글 3개
게시글 목록
| 번호 | 제목 |
|---|---|
| 1269 |
디자이너
웹에 jpg파일 업로드시...
2
|
| 1264 | |
| 1256 | |
| 1251 | |
| 1235 | |
| 1232 |
기획자
돌아감서 출첵
2
|
| 1225 | |
| 1216 |
디자이너
허머 ㅠㅠ 로고가...
8
|
| 1214 | |
| 1208 | |
| 1204 |
디자이너
사자공격 동영상
3
|
| 1195 |
디자이너
T800
8
|
| 1190 |
개발자
솔루션 제작시...
4
|
| 1187 | |
| 1181 | |
| 1180 |
디자이너
Daum 카페와 같은 메뉴의 스킨
|
| 1179 | |
| 1169 | |
| 1155 |
디자이너
포토샵 인증때문에ㅠㅠ
13
|
| 1143 |
기획자
티몬사이트 기획
11
|
| 1142 |
디자이너
펜톤컬러도 플러그인인가요?
|
| 1141 |
개발자
글쓰기...오류
|
| 1140 |
개발자
값이 안넘어가 지네요
|
| 1135 |
디자이너
이게 무슨서체인가요~
4
|
| 1134 | |
| 1130 | |
| 1119 | |
| 1118 | |
| 1116 | |
| 1112 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기