|
Server : Apache/2.2.17 (Unix) mod_ssl/2.2.17 OpenSSL/0.9.8e-fips-rhel5 DAV/2 PHP/5.2.17 System : Linux localhost 2.6.18-419.el5 #1 SMP Fri Feb 24 22:47:42 UTC 2017 x86_64 User : nobody ( 99) PHP Version : 5.2.17 Disable Function : NONE Directory : /home/queenjbs/www/member/ |
Upload File : |
<?include "./mypage_left.php";?>
<?
if(!$pageCount) $pageCount = 25;
$show_one_page = $pageCount;
$show_view_page = 10;
$page = ( $page ) ? $page : 1;
$offset = ($page-1)*$show_one_page;
if($key_word) {
if($key == "jname" || $key == "jname2" || $key == "nickname"){
$key_word = str_replace(" ","",$key_word);
$where = "AND $key like '%".$key_word."%' ";
}else{
$key_word = str_replace(" ","",$key_word);
$where = "AND UPPER(".$key.") like '%".strtoupper($key_word)."%' ";
}
}
if($tabs == 2){
$order_by = ' ORDER BY member_code desc ,m_startdate DESC';
}else{
$order_by = ' ORDER BY no DESC';
}
if($sort == '1'){
$order_by = ' ORDER BY m_enddate asc';
}
$url_tail = "&tab=$tab&tabs=$tabs&key=$key&order_by=$order_by&LK=$LK&sort=$sort";
if(!$key_word) {
$query_limit = "limit $offset,$show_one_page";
}
$total_count = get_db("SELECT count(*) FROM board_qna where user_no = '$mIdx' and is_delete ='N' $where $CoWhere $order_by");
$QUERY_PAGE = "SELECT * FROM board_qna where user_no = '$mIdx' and is_delete ='N' $where $CoWhere $order_by $query_limit";
//echo $QUERY_PAGE."<br>";
$total_page = ceil( $total_count / $show_one_page);
$viewlist2 = ( !$total_count ) ? "" : Get_viewpage2($page,$total_count,$show_one_page,$show_view_page,$url_tail);
$start_num = $total_count - $offset; //
$result= mysql_query($QUERY_PAGE,$db_con);
if(!$result) {
error("DB_ERROR");
exit;
}
$total = mysql_affected_rows();
?>
<div class="mypg_center">test</div>
<div class="mypg_right">
<div class="article2"> <!-- article area -->
<h3>Q&A</h3>
<ul class="qna_ti">
<li class="number">番号</li>
<li class="title">タイトル</li>
<li class="date3">記入日</li>
<li class="treat">処理</li>
</ul>
<dl>
<!--dt>
<ul class="dt_ti">
<li class="number_s">2</li>
<li class="title_s">
<span class="q">Q</span>
Test Article Test Article Test Article Test Article
</li>
<li class="date_s">2012-04-13</li>
<li class="treat_s"><span class="blue">未決</span></li>
</ul>
</dt-->
<?
if(!$total){
echo "<dt>登録された情報がございません</dt>";
}else{
for($i=0; $i<$total_count; $i++) {
$Num = $start_num - $i;
$row = mysql_fetch_array($result);
$created = substr($row[reg_date],0,10);
$resub = Get_dbres("select tel from user_profiles where user_id = '$row[id]'");
$rows = mysql_fetch_array($resub);
if($row[mChk] == 1){
$bgColor ="#dddddd";
}else{
$bgColor ="#ffffff";
}
?>
<dt>
<a href="javascript:chklist('<?=$Num?>');">
<ul class="dt_ti">
<li class="number_s"><?=$Num?></li>
<li class="title_s">
<span class="q">Q</span>
<?=$row[subject]?>
</li>
<li class="date_s"><?=$created?></li>
<li class="treat_s">
<?if($row[original_no] == 1){?>
<span class="pink">解決済み</span>
<?}else{?>
<span class="blue">未決</span>
<?}?>
</li>
</ul>
</a>
</dt>
<dd id="list<?=$Num?>" style="display:none;">
<p>
<span>[質問内容]</span><br />
<?=$row[contents]?>
</p>
<h4>
<?if($row[original_no] == 1){?>
<span class="blue">A</span>
[答え内容] <?=substr($row[modify_date],0,10)?>
</h4>
<p>
<?=$row[reply_content]?>
</p>
<?}?>
</dd>
<?
$Num--;
}
}
?>
</dl>
<div class="btn_extension_b"><a href="/member/?tab=12&tabs=6&mode=write"><img src="/images/member/btn_write.gif" style="cursor:pointer"/></a></div>
</div> <!-- /article -->
</div> <!-- mypg_right -->
</div> <!-- mypg_cont -->
<script>
function chklist(val){
if(document.all("list"+val).style.display == "none"){
$('#list'+val).fadeIn('slow');
//document.all("list"+val).style.display='';
document.all("listBtn"+val).src='/images/sub/btn_fold_on.gif';
}else{
$('#list'+val).fadeOut('slow');
//document.all("list"+val).style.display='none';
document.all("listBtn"+val).src='/images/sub/btn_fold_off.gif';
}
}
</script>