경로 및 전체테이블명 변경

This commit is contained in:
gnuboard
2013-02-07 16:56:29 +09:00
parent d7b9aab47a
commit f7855b165c
184 changed files with 711 additions and 708 deletions

View File

@ -20,7 +20,7 @@ else
$delivery = (int)$tmp[0];
}
$sql =" select * from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
@ -35,24 +35,24 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$ca_name4 = "";
$ca_id1 = substr($row[ca_id],0,2);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id1' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id1' ");
$ca_name1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 4) {
$ca_id2 = substr($row[ca_id],0,4);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id2' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id2' ");
$ca_name2 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$ca_id3 = substr($row[ca_id],0,6);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id3' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id3' ");
$ca_name3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 8) {
$ca_id4 = substr($row[ca_id],0,8);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id4' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id4' ");
$ca_name4 = $row2[ca_name];
}

View File

@ -21,7 +21,7 @@ else
}
$time = date("Y-m-d 00:00:00", $g4[server_time] - 86400);
$sql =" select * from $g4[yc4_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
@ -36,24 +36,24 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$ca_name4 = "";
$ca_id1 = substr($row[ca_id],0,2);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id1' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id1' ");
$ca_name1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 4) {
$ca_id2 = substr($row[ca_id],0,4);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id2' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id2' ");
$ca_name2 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$ca_id3 = substr($row[ca_id],0,6);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id3' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id3' ");
$ca_name3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 8) {
$ca_id4 = substr($row[ca_id],0,8);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$ca_id4' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$ca_id4' ");
$ca_name4 = $row2[ca_name];
}

View File

@ -60,26 +60,26 @@ else
$delivery = (int)$tmp[0];
}
$sql =" select * from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$ca_name1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 4) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$ca_name2 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$ca_name3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 8) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$ca_name4 = $row2[ca_name];
}

View File

@ -63,26 +63,26 @@ else
}
$time = date("Y-m-d 00:00:00", $g4[server_time] - 86400);
$sql =" select * from $g4[yc4_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$ca_name1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 4) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$ca_name2 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$ca_name3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 8) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$ca_name4 = $row2[ca_name];
}

View File

@ -20,7 +20,7 @@ ob_start();
$lt = "[[";
$gt = "]]";
$sql =" select * from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)

View File

@ -28,7 +28,7 @@ include_once("./_common.php");
<?
// <p>상품번호^대분류^중분류^소분류^제조사^모델명^상품Url^이미지Url^가격
$str = "";
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id ";
$result = sql_query($sql);
@ -36,13 +36,13 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$image = it_image("$row[it_id]_m");
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
if (strlen($row[ca_id]) >= 4)
$row3 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row3 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
if (strlen($row[ca_id]) >= 6)
$row4 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row4 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
// 재고검사해서 없으면 상품가격을 0 으로 설정
$stock = get_it_stock_qty($row[it_id]);

View File

@ -9,16 +9,16 @@ echo $_SERVER["HTTP_HOST"];
// \n상품코드#대분류#소분류#상품명#상품URL#가격
$str = "";
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id ";
$result = sql_query($sql);
for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
if (strlen($row[ca_id]) >= 4)
$row3 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row3 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$str .= "\n";
$str .= "$row[it_id]#$row2[ca_name]#$row3[ca_name]#$row[it_name]#$g4[shop_url]/item.php?it_id=$row[it_id]#$row[it_amount]";

View File

@ -19,16 +19,16 @@ else
<?
// 상품ID^카테고리^상품명^제조사^이미지URL^상품URL^가격^적립금^할인쿠폰^무이자할부^사은품^모델명^추가정보^출시일^배송료
$str = "";
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id ";
$result = sql_query($sql);
for ($i=0; $row=mysql_fetch_array($result); $i++) {
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$ca_name = $row2[ca_name];
if (strlen($row[ca_id]) >= 4) {
$row3 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row3 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$ca_name .= "|" . $row3[ca_name];
}

View File

@ -79,31 +79,31 @@ else {
$deliv2 = (int)$send_cost_list[0]."";
}
$sql =" select * from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
{
$cate1 = $cate2 = $cate3 = $cate4 = "";
$row2 = sql_fetch(" select ca_id, ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_id, ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$cate1 = $row2[ca_id];
$catename1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 8) {
$row2 = sql_fetch(" select ca_id, ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$row2 = sql_fetch(" select ca_id, ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$cate4 = $row2[ca_id];
$catename4 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$row2 = sql_fetch(" select ca_id, ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row2 = sql_fetch(" select ca_id, ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$cate3 = $row2[ca_id];
$catename3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 4) {
$row2 = sql_fetch(" select ca_id, ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row2 = sql_fetch(" select ca_id, ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$cate2 = $row2[ca_id];
$catename2 = $row2[ca_name];
}

View File

@ -48,7 +48,7 @@ include_once("./_common.php");
// 페이지당 행수
$page_rows = 1000;
$sql = " select count(*) as cnt from $g4[yc4_item_table] where it_use = '1' and ca_id LIKE '$ca_id%'";
$sql = " select count(*) as cnt from $g4[shop_item_table] where it_use = '1' and ca_id LIKE '$ca_id%'";
$row = sql_fetch($sql);
$total_count = $row[cnt];
?>
@ -89,7 +89,7 @@ if ($page == "") $page = 1;
$from_record = ($page - 1) * $page_rows;
$caid = addslashes($ca_id);
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
and ca_id LIKE '$caid%'
order by ca_id

View File

@ -48,7 +48,7 @@ include_once("./_common.php");
// 페이지당 행수
$page_rows = 1000;
$sql = " select count(*) as cnt from $g4[yc4_item_table] where it_use = '1' and ca_id LIKE '$ca_id%'";
$sql = " select count(*) as cnt from $g4[shop_item_table] where it_use = '1' and ca_id LIKE '$ca_id%'";
$row = sql_fetch($sql);
$total_count = $row[cnt];
?>
@ -95,7 +95,7 @@ if ($page == "") $page = 1;
$from_record = ($page - 1) * $page_rows;
$caid = addslashes($ca_id);
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
and ca_id LIKE '$caid%'
order by ca_id

View File

@ -34,7 +34,7 @@ th,td {font-family:굴림; font-size:10pt ; height:15pt}
$url = "http://" . $_SERVER["HTTP_HOST"] . dirname($_SERVER["PHP_SELF"]);
$sql =" SELECT LENGTH(ca_id)=2 AS cnt, ca_id
FROM $g4[yc4_category_table]
FROM $g4[shop_category_table]
HAVING cnt";
$result = @mysql_query($sql);
@ -42,11 +42,11 @@ $tr = "";
for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".$row[ca_id]."'");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".$row[ca_id]."'");
echo $tr;
echo " <td align=center><a href='./enuri.php?ca_id=$row[ca_id]'>$row2[ca_name]</a></td>\n";
$str = " <td>";
$sql3 = "select ca_name,ca_id from $g4[yc4_category_table] where ca_id LIKE '".$row[ca_id]."%' AND LENGTH(ca_id) !=2 AND LENGTH(ca_id) < 5";
$sql3 = "select ca_name,ca_id from $g4[shop_category_table] where ca_id LIKE '".$row[ca_id]."%' AND LENGTH(ca_id) !=2 AND LENGTH(ca_id) < 5";
$result3 = @mysql_query($sql3);
$bar = "";

View File

@ -49,7 +49,7 @@ include_once("./_common.php");
// 페이지당 행수
$page_rows = 100;
$sql = " select count(*) as cnt from $g4[yc4_item_table] where it_use = '1' ";
$sql = " select count(*) as cnt from $g4[shop_item_table] where it_use = '1' ";
$row = sql_fetch($sql);
$total_count = $row[cnt];
?>
@ -86,7 +86,7 @@ if ($page == "") $page = 1;
// 시작 레코드 구함
$from_record = ($page - 1) * $page_rows;
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id
limit $from_record, $page_rows ";
@ -103,7 +103,7 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$code = substr($row[ca_id],0,$k*2);
$sql3 = " select ca_name from $g4[yc4_category_table] where ca_id = '$code' ";
$sql3 = " select ca_name from $g4[shop_category_table] where ca_id = '$code' ";
$row3 = sql_fetch($sql3);
$category .= $bar . $row3[ca_name];

View File

@ -52,7 +52,7 @@ else {
$send_cost = (int)$send_cost_list[0];
}
$sql =" select * from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
@ -61,24 +61,24 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$caid1 = $caid2 = $caid3 = $caid4 = "";
$caid1 = substr($row[ca_id],0,2);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid1' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid1' ");
$cate1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 8) {
$caid4 = substr($row[ca_id],0,8);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid4' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid4' ");
$cate4 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$caid3 = substr($row[ca_id],0,6);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid3' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid3' ");
$cate3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 4) {
$caid2 = substr($row[ca_id],0,4);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid2' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid2' ");
$cate2 = $row2[ca_name];
}

View File

@ -56,7 +56,7 @@ else {
// 하루전의 상품
$time = date("Y-m-d 00:00:00", $g4[server_time] - 86400);
$sql =" select * from $g4[yc4_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)
@ -65,24 +65,24 @@ for ($i=0; $row=sql_fetch_array($result); $i++)
$caid1 = $caid2 = $caid3 = $caid4 = "";
$caid1 = substr($row[ca_id],0,2);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid1' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid1' ");
$cate1 = $row2[ca_name];
if (strlen($row[ca_id]) >= 8) {
$caid4 = substr($row[ca_id],0,8);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid4' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid4' ");
$cate4 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 6) {
$caid3 = substr($row[ca_id],0,6);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid3' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid3' ");
$cate3 = $row2[ca_name];
}
if (strlen($row[ca_id]) >= 4) {
$caid2 = substr($row[ca_id],0,4);
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '$caid2' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '$caid2' ");
$cate2 = $row2[ca_name];
}

View File

@ -22,7 +22,7 @@ $lt = "<<<";
$gt = ">>>";
$time = date("Y-m-d 00:00:00", $g4[server_time] - 86400);
$sql =" select * from $g4[yc4_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$sql =" select * from $g4[shop_item_table] where it_use = '1' and it_time >= '$time' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)

View File

@ -19,7 +19,7 @@ Field Status Notes
$lt = "<<<";
$gt = ">>>";
$sql =" select it_id, it_name, it_amount, it_time from $g4[yc4_item_table] where it_use = '1' order by ca_id";
$sql =" select it_id, it_name, it_amount, it_time from $g4[shop_item_table] where it_use = '1' order by ca_id";
$result = sql_query($sql);
for ($i=0; $row=sql_fetch_array($result); $i++)

View File

@ -15,19 +15,19 @@ include_once("./_common.php");
<?
// <p>상품번호^대분류^중분류^소분류^제조사^모델명^상품Url^가격
$str = "";
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id ";
$result = sql_query($sql);
for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
if (strlen($row[ca_id]) >= 4)
$row3 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row3 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
if (strlen($row[ca_id]) >= 6)
$row4 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row4 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
// 재고검사해서 없으면 상품가격을 0 으로 설정
$stock = get_it_stock_qty($row[it_id]);

View File

@ -33,7 +33,7 @@ include_once("./_common.php");
// 페이지당 행수
$page_rows = 500;
$sql = " select count(*) as cnt from $g4[yc4_item_table] where it_use = '1' ";
$sql = " select count(*) as cnt from $g4[shop_item_table] where it_use = '1' ";
$row = sql_fetch($sql);
$total_count = $row[cnt];
?>
@ -76,24 +76,24 @@ if ($page == "") $page = 1;
// 시작 레코드 구함
$from_record = ($page - 1) * $page_rows;
$sql = " select * from $g4[yc4_item_table] where it_use = '1' order by ca_id limit $from_record, $page_rows ";
$sql = " select * from $g4[shop_item_table] where it_use = '1' order by ca_id limit $from_record, $page_rows ";
$result = sql_query($sql);
for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$row2 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
$row2 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,2)."' ");
if (strlen($row[ca_id]) >= 4)
$row3 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
$row3 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,4)."' ");
else
$row3[ca_name] = "&nbsp;";
if (strlen($row[ca_id]) >= 6)
$row4 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
$row4 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,6)."' ");
else
$row4[ca_name] = "&nbsp;";
if (strlen($row[ca_id]) >= 8)
$row5 = sql_fetch(" select ca_name from $g4[yc4_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
$row5 = sql_fetch(" select ca_name from $g4[shop_category_table] where ca_id = '".substr($row[ca_id],0,8)."' ");
else
$row5[ca_name] = "&nbsp;";

View File

@ -49,7 +49,7 @@ include_once("./_common.php");
// 페이지당 행수
$page_rows = 100;
$sql = " select count(*) as cnt from $g4[yc4_item_table] where it_use = '1' ";
$sql = " select count(*) as cnt from $g4[shop_item_table] where it_use = '1' ";
$row = sql_fetch($sql);
$total_count = $row[cnt];
?>
@ -88,7 +88,7 @@ if ($page == "") $page = 1;
// 시작 레코드 구함
$from_record = ($page - 1) * $page_rows;
$sql = " select * from $g4[yc4_item_table]
$sql = " select * from $g4[shop_item_table]
where it_use = '1'
order by ca_id
limit $from_record, $page_rows ";
@ -103,7 +103,7 @@ for ($i=0; $row=mysql_fetch_array($result); $i++)
{
$code = substr($row[ca_id],0,$i*2);
$sql3 = " select ca_name from $g4[yc4_category_table] where ca_id = '$code' ";
$sql3 = " select ca_name from $g4[shop_category_table] where ca_id = '$code' ";
$row3 = sql_fetch($sql3);
$category .= $bar . $row3[ca_name];