/home/mjc1/public_html/html/ezpos/html/support/customercpds.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
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
<?
    
if (!isset($uid)) $uid "";
    if (!isset(
$retValue)) $retValue "";
    if (!isset(
$pg)) $pg "";
    if (!isset(
$boardId)) $boardId "";
    if (!isset(
$mode)) $mode "";
    if (!isset(
$searchCode)) $searchCode "";
    if (!isset(
$keyword)) $keyword "";
/*
    if( isset($nuid) && $nuid !== ""){

        if( !isset(${"noticeBoardUid_".$nuid}) ){
    
         $hitSel     =  " select hit from mBoard_etc_store WHERE uid = '$uid' union select hit from mBoard_pro_store WHERE uid = '$uid'";
         $hitResult  =    mysql_query($hitSel);
         $hitRow     =    mysql_fetch_array($hitResult);
         $plus_hit   =    $hitRow[0] + 1;
         $plus_hit2   =    $hitRow[0] + 1;
         $hitUp  =  " UPDATE mBoard_etc_store SET hit = '$plus_hit' WHERE uid = '$uid' ";
         $hitUp2  =     " UPDATE mBoard_pro_store SET hit = '$plus_hit2' WHERE uid = '$uid' ";
                      MYSQL_QUERY($hitUp );
                      MYSQL_QUERY($hitUp2 );
      
         setcookie("etc_storeUid_$uid",$uid,0);
        }  
    }  */
?>

<? include("../common/sub_header.php"); ?>

    <div class="wrap">

        <div class="contents">
            <div class="asideMenu">
                <? include("./leftNavi.html"); ?>
            </div><!-- //leftNavi -->

            <div class="subContents">
                <h1>
                    <img src="../../images/titlebar/support_customercpds.png" alt="ÆÄÀÏÀÚ·á½Ç">
                    <p>
                        <span class="home"><a href="intro.php">Home</a></span>
                        <span class="depth">></span>
                        <span class="depth1">°í°´Áö¿ø</span>
                        <span class="depth">></span>
                        <span class="depth2">ÆÄÀÏÀÚ·á½Ç</span>
                    </p>
                </h1>

                <!-- ¼­ºê³»¿ë -->
                <div class="section">

<?
   $cm_nCount          
=      15;
   
$cm_item_nCount     =      30;          
   
   function 
pageListing($cur_page$total_page$n$url) {

    
$retValue "<div>";
    if (
$cur_page 1) {
        
$retValue .= "<a href='" $url . ($cur_page-1) ."' class=pgPrev><span class=screen_out>¾ÕÀ¸·Î</span></a>";
    } else {
        
$retValue .= "";
    }
    
$retValue .= "";
    
$start_page = ( ( (int)( ($cur_page ) / 10 ) ) * 10 ) + 1;
    
//echo (int)(($cur_page - 1) / 10);
    
$end_page $start_page 9;
    if (
$end_page >= $total_page$end_page $total_page;
    
    if (
$start_page 1$retValue .= "<a href='" $url . ($start_page-1) . "' class=pgFirst><span class=screen_out>10ÆäÀÌÁö ¾ÕÀ¸·Î</span></a>";
    
    if (
$total_page 1)
    for (
$k=$start_page;$k<=$end_page;$k++)
        if (
$cur_page != $k$retValue .= "<a href='$url$k'>$k</a>";
        else 
$retValue .= "<a class=on>$k</a>";
    
    if (
$total_page $end_page$retValue .= "<a href='" $url . ($end_page+1) . "' class=pgLast><span class=screen_out>10ÆäÀÌÁö µÚ·Î</span></a>";
    
$retValue .= "";
    
    if (
$cur_page $total_page) {
    
$retValue .= "<a href='$url. ($cur_page+1) ."' class=pgNext><span class=screen_out>µÚ·Î</span></a>";
    } else {
        
$retValue .= "";
  }
  
$retValue .= "</div>";
  return 
$retValue;
}
?>

<?
    $dbtable   
=  "mBoard_etc_store";
    
$dbtable   =  "mBoard_pro_store";

    if( isset(
$uid) && $uid !== ""){

        
$oneQry     =   " select * from mBoard_etc_store  WHERE uid = '$uid' union select * from mBoard_pro_store WHERE uid = '$uid' ";

        
$oneResult  =     mysql_query($oneQry);

        
$oneRow     =     mysql_fetch_array($oneResult);
        
$content nl2br(stripslashes($oneRow['content']));

?>

                    <!-- board -->
                    <div class="board">
                        <h2 class="screen_out">ÀÚ·á½Ç »ó¼¼±ÛÀÔ´Ï´Ù</h2>
                
                        <!-- ±Û1 -->
                        <dl>
                            <dt>
                                <ul class="noticeBoard">
                                    <li class="noticeNum_d"><?=$oneRow['uid'];?></li>
                                    <li class="noticeTitle_d"><?=stripcslashes($oneRow['subject']);?></li>
                                </ul>
                            </dt>

                            <!-- ±ÛÁ¦¸ñ -->
                            <dd>
                                <ul class="upgradeManual">
                                    <li class="attachL">÷ºÎÆÄÀÏ</li>
                                    <li class="attachR">
                                        <a href='fileDownLoad.php?type=etc_store&filename=<?=$oneRow['add_file'];?>'>[ ÆÄÀÏ´Ù¿î·Îµå ]</a>
                                    </li>
                                </ul>
                            </dd>

                            <dd>
                                <p class="noticeContents"><?=$content;?></p>
                            </dd>
                            <!-- ±ÛÁ¦¸ñ ³¡ -->
                        </dl>
                    </div>

                    <!-- ±Û¸ñ·Ï -->
                    <a href="customeretcpds.php"><div class="listBtn"><span class="screen_out">±Û¸ñ·Ï ¹öư</span></div></a>

<?     }    ?> 

                    <!-- board -->
                    <div class="board">
                        <h2 class="screen_out">ÆÄÀÏÀÚ·á½Ç °Ô½ÃÆÇÀÔ´Ï´Ù.</h2>
                
                        <!-- ±Û1 -->
                        <dl>
                            <dt>
                                <ul class="noticeBoard">
                                    <li class="pdsNum">¹ø È£</li>
                                    <li class="pdsTitle">Á¦ ¸ñ</li>
                                    <li class="pdsDate">ÀÛ¼ºÀÏ</li>
                                    <li class="pdsCount">Á¶È¸¼ö</li>
                                </ul>
                            </dt>

<?
    
if( isset($keyword_new) && $keyword_new !== ""){
        if( 
$searchCode_new == '1')  $Code =  " and subject like  '%$keyword_new%' ";
        if( 
$searchCode_new == '2')  $Code =  " and content like '%$keyword_new%' ";
    }

    
$total_sql  =   " select * from mBoard_etc_store union select * from mBoard_pro_store ";

    
$result      mysql_query($total_sql) or die (mysql_error());
    
$nTotalCount mysql_num_rows($result);
    
$nPage       ceil($nTotalCount $cm_nCount);
    if (
$pg_new == ""$pg_new 1;
    
$nFrom = ($pg_new 1) * $cm_nCount;

    
$sql    $total_sql "  order by uid DESC limit $nFrom$cm_nCount ";

    
$result mysql_query($sql) or die (mysql_error());

        if( 
mysql_num_rows($result) > ){ 
            while (
$Row =  mysql_fetch_array($result)){ 

?>    
                            <!-- ±ÛÁ¦¸ñ -->
                            <dd>
                                <ul class="noticeSubject">
                                    <li class="pdsNum"><?=$Row['uid'];?></li>
                                    <li class="pdsTitle"><a href='customercpds.php?uid=<?=$Row['uid'];?>&pg=<?=$pg_new;?>&boardId=<?=$boardId_new;?>'><?=stripcslashes($Row['subject']);?></a></li>
                                    <li class="pdsDate"><?=date('Y-m-d',$Row['reg_date']);?></li>
                                    <li class="pdsCount"><?=$Row['hit'];?></li>
                                </ul>
                            </dd>
<?
    
}
  }  
?>              

                            <!-- ±ÛÁ¦¸ñ ³¡ -->
                        </dl>
                    </div>

                    <!-- ÆäÀÌ¡ -->
                    <div class="paginate">
                        <?=pageListing($pg$nPage$cm_nCount"customercpds.php?pg=" );?>
                    </div>

                </div><!-- //section -->
        
            </div><!-- //subContents -->
        </div><!-- //contents -->
    </div><!-- //wrap -->

<? include("../common/sub_footer.php"); ?>