/home/mjc1/public_html/onlinecs/mobile/header.php


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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
<?
@error_reportingE_CORE_ERROR E_CORE_WARNING E_COMPILE_ERROR E_ERROR E_WARNING E_PARSE E_USER_ERROR E_USER_WARNING );
session_start();
@
extract($_GET);
@
extract($_POST);
@
extract($_SESSION);
@
extract($_COOKIE);
if(!isset(
$_SESSION['id'])) $_SESSION['id'] = "";     // Notice Error 방지

if(!isset($sname))            $sname "";            // Notice Error 방지
if(!isset($id))                $id "";                // Notice Error 방지

$nowDate date("Y-m-d"time());

/* jyh 디버깅 함수 */
function prt($data=null$size=0) {
    
//if (!isdev()) return;
    
ob_start();
    
print_r($data);
    
$content_text ob_get_contents();
    
ob_end_clean();
    
$content_list explode("\n"$content_text);
    
$rows count($content_list);
    
$cols 0;
    foreach (
$content_list as $line) {
        if ((
$col mb_strlen($line)) > $cols) {
            
$cols $col;
            if (
$cols 128$rows++;
        }
    }
    
$rows += 2;
    
$cols += 2;
    if (!
headers_sent()) {
        
header('Content-type: text/html; charset=utf-8');
    }
    echo 
'<textarea cols="' $cols '" rows="' $rows '"';
    echo 
' style="display:block; margin:0; padding:5px; border:1px solid #999;';
    if (
$size) echo ' width:' $size 'px;';
    echo 
' font-family:Hwsr_9pt, Gulimche; font-size:9pt;">';
    echo 
$content_text;
    echo 
'</textarea>';
}

include_once(
"./commonST2.php");

$charSet_sql "set names utf8";      
mysql_query($charSet_sql);

// 온라인 주문 배송 정보 사용에 다른 옵션 가져오기
$sql "select optvalue from options where optname = '온주배송정보사용' ";
$res_optval1 mysql_query($sql);
$info_optval1 mysql_fetch_array($res_optval1);
$sid $sid."x";    $sid substr($sid,0,strlen($sid)-1);

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>천년스마트발주</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=3.0, minimum-scale=1.0, user-scalable=yes" />
    <!-- 호환성 보기 적용 North Carolina State University -->
    <meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7,IE=EmulateIE8,IE=EmulateIE9,IE=EmulateIE10,IE=EmulateIE11" />    
    <link rel="stylesheet" type="text/css" href="css/basic.css" />
    <script type="text/javascript" src="js/jquery-1.8.3.min.js"></script>
    <script type="text/javascript" src="js/jqueryui/jquery-ui.js"></script>
    <link rel="stylesheet" type="text/css" href="js/jqueryui/jquery-ui.css" />
    <script>
    // 로그인
    function login(){
        //location.href =  "./login.php";
        location.replace("./login.php");        
    }
    // 로그아웃
    function logout(){
        //login_ifm.location.href =  "./logout.php";
        login_ifm.location.replace("./logout.php");        
    }    
    </script>
</head>
<body>
<?
// Notice Error 방지
if(!isset($cuscode)) $cuscode "";
if(!isset(
$sacode))    $sacode    "";
?>
<script>
$(function(){
    $("#orddate").change(function(){
        var v = $(this).val();
        preg_replace2("date",v,$(this));
    });
    $("#deldate").change(function(){
        var v = $(this).val();
        preg_replace2("date",v,$(this));
    });
});
function preg_replace2(vt,vv,obj){
    $.ajax({type:"post", url:"ajax.preg_replace.php?vt="+vt+"&vv="+vv, async:false, dataType : "html", 
        success:function(rtn){    
            $(obj).val(rtn);
        },
        error:function(rtn,status,error){

        }
    });
}
</script>
<div class="warp">
    <iframe name="login_ifm" width="0" height="0" style="border:0px"></iframe>
    <input id="toggle" type="checkbox" />
    <div class="wrap">
        <div class="main_header">
            <a class="left" href="./index.php">홈</a>
            <h1 class="logo"><a href="./index.php"><span class="screen_out">천년스마트발주</span></a></h1>
            <label class="right" for="toggle" onclick="">바로가기</label>
        </div>

        <div class="toggle_gnb_wrap">
            <div class="toggle_gnb">
                <ul>
                    <li class="gnb_write"><a href="./buyWrite.php?detail=y&txtdate=<?=$nowDate?>&txtdate2=<?=$nowDate?>&new=y">발주등록</a></li>
                    <li class="gnb_news"><a href="./notice.php?cuscode=<?=$cuscode?>&ocode=<?=$sacode?>&part=1">공지사항</a></li>
                    <li class="gnb_cs"><a href="./CScenter.php">고객센터</a></li>
                    <li class="gnb_pwd"><a href="./chgPwd.php">암호변경</a></li>
                </ul>
            </div>
        </div>
        <script type="text/javascript">
            $(".main_header label").click(function() {
                //$(".toggle_gnb_wrap").slideToggle("fast");
                $(".toggle_gnb_wrap").slideToggle("slow");
            })
        </script>
        <div class="lnb">
            <!--div><a href="sell.php">수주</a></div-->
            <!--div><a href="javascript:alert('준비중 입니다.')">수주</a></div-->
            <div><a href="./buy.php">발주조회</a></div>
            <?
            
if($custom_order=='1'){
            
?>
            <div><a href="./buyWrite_new1.php">발주등록</a></div>
            <?
            
// 개구리서적 주문개발 처리
            
} else if($_SESSION['sa_uid'] == "hschina"){
            
?>
                <div><a href="./popcategory.php?uid=&nidx=1">발주등록</a></div>
            <?
            
} else if($sid == "ggrbook" || $sid == "gyu1001" || $info_optval1['optvalue']=='1'){    
            
?>
                <div><a href="./buyWrite_order.php?detail=y&txtdate=<?=$nowDate?>&txtdate2=<?=$nowDate?>&new=y">발주등록</a></div>
            <?
            
} else if($_SESSION['sa_uid'] == "hschina"){ 
            
?>
            <?}else{?>
                <div><a href="./buyWrite.php?detail=y&txtdate=<?=$nowDate?>&txtdate2=<?=$nowDate?>&new=y">발주등록</a></div>
            <?}?>            
            <!--div><a href="sell_list.php">매입처원장</a></div-->
            <!--div><a href="javascript:alert('준비중 입니다.')">매입처원장</a></div-->
            <div><a href="./buy_list.php">거래원장</a></div>
            <!--div><a href="login.php">로그인</a></div-->
            <div><?if($id){?><a href="javascript:logout();">로그아웃</a><?}else{?><a href="#" onclick="javascript:login();">로그인</a><?}?></div>
        </div>