? GR0V Shell

GR0V shell

Linux www.koreapackagetour.com 2.6.32-042stab145.3 #1 SMP Thu Jun 11 14:05:04 MSK 2020 x86_64

Path : /home/admin/public_html/old/happyezystyle/
File Upload :
Current File : /home/admin/public_html/old/happyezystyle/Webboard.php

<? include("header.php");?>
<table width="1000" border="0" align="center" cellpadding="0" cellspacing="0">
  <!-- fwtable fwsrc="Untitled" fwbase="home.jpg" fwstyle="Dreamweaver" fwdocid = "742308039" fwnested="0" -->
  <tr>
   <td><img src="images/spacer.gif" width="423" height="1" border="0" alt=""></td>
   <td><img src="images/spacer.gif" width="16" height="1" border="0" alt=""></td>
   <td><img src="images/spacer.gif" width="225" height="1" border="0" alt=""></td>
   <td><img src="images/spacer.gif" width="315" height="1" border="0" alt=""></td>
   <td><img src="images/spacer.gif" width="21" height="1" border="0" alt=""></td>
   <td><img src="images/spacer.gif" width="1" height="1" border="0" alt=""></td>
  </tr>

  
  <tr>
    <td colspan="5" bgcolor="#FFFFFF"><div align="center"> 
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
          <tr valign="top"> 
            <td width="190"><table width="100%" border="0" cellspacing="1" cellpadding="1">
                <tr>
                  <td><div align="center"> <? echo "$showmember"; ?></div></td>
                </tr>
                <tr> 
                  <td><img src="images/index_09.jpg" width="241" height="49" alt=""></td>
                </tr>
                <tr> 
                  <td> 
                    <?
$page = $_GET['page'];
$select_type="select * from productstype  order by id asc";
$query_select=mysql_query($select_type);
$num_rows=mysql_num_rows($query_select);

if($num_rows<1){
echo "<br><br><center><b>ยังไม่มีการเพิ่มข้อมูลค่ะ</b></center>";
}else{
		$select="select * from productstype  order by id asc";
		$q_ry = mysql_query($select);
	 	$num_rows=mysql_num_rows($q_ry);
  		$pagesize=20;
		$rt=$num_rows%$pagesize;
		if($rt!=0)
			{
				$totalpage=floor($num_rows/$pagesize)+1;
			}
		else
			{
				$totalpage=floor($num_rows/$pagesize);
				$toppic_id=1;
			}
		if(empty($page))
			{
				$page=1;
			}
		mysql_free_result($q_ry);
		$goto=($page-1)*$pagesize;
$sql_select_mem="Select * From productstype  order by id asc limit $goto,$pagesize";
		$fect=mysql_query($sql_select_mem);
		if(!$fect)
		{
		("ติดต่อฐานข้อมูลไม่ได้".mysql_error());
		exit;
		}

	  $bgcount=0;
	while($rows=mysql_fetch_array($fect))
	{
$idx =$rows['id'];
$productstypecode  =$rows['productstypecode'];
$productstypename = $rows['productstypename'];
$bgcount=$bgcount+1;
$bgmod=$bgcount%2;
if($bgmod==0){
	$bgcolor="#E9E9E8";
}else{
	$bgcolor="#FFFFFF";
}

$s_num="select * from products where productstypecode = '$productstypecode'";
$query_select_num=mysql_query($s_num);
$snum=mysql_num_rows($query_select_num);
	?>
                    <table width="100%" border="0" cellspacing="1" cellpadding="1">
                      <tr> 
                        <td height="23"> <div align="left"></div>
                          <div align="left"></div>
                          <div align="center"> </div>
                          <div align="left"><img src="images/bullet/bt04.gif" width="14" height="14"><? echo "<a href=ProductList.php?PRD=$productstypecode>$productstypename</a> ($snum)"; ?></div></td>
                      </tr>
                      <tr> 
                        <td height="5"><img src="images/inline.jpg" width="184" height="3"></td>
                      </tr>
                    </table>
                    <?
}
}
?>                  </td>
                </tr>
                <tr> 
                  <td>&nbsp;</td>
                </tr>
            </table></td>
            <td><table width="100%" border="0" cellspacing="1" cellpadding="1">
                <tr> 
                  <td><strong>กระดานข่าว</strong></td>
                </tr>
                <tr> 
                  <td><table width="99%" border="0" cellspacing="1" cellpadding="1">
                      <tr> 
                        <td><table width="100%" border="0" cellspacing="4" cellpadding="4">
                            <tr> 
                              <td><table width="100%" border="0" cellspacing="1" cellpadding="1">
                                  <tr> 
                                    <td><table width="41%" border="0" cellspacing="3" cellpadding="3">
                                        <tr> 
                                          <td width="49%" background="images/bg.jpg"> 
                                            <div align="center"><a href="index.php">&#3652;&#3611;&#3627;&#3609;&#3657;&#3634;&#3627;&#3621;&#3633;&#3585;</a></div></td>
                                          <td width="51%" background="images/bg.jpg"> 
                                            <div align="center"><a href="NewTopic.php">&#3605;&#3633;&#3657;&#3591;&#3585;&#3619;&#3632;&#3607;&#3641;&#3657;&#3651;&#3627;&#3617;&#3656;</a></div></td>
                                        </tr>
                                      </table></td>
                                  </tr>
                                  <tr> 
                                    <td><table width="100%" border="0" cellspacing="1" cellpadding="1">
                                        <tr> 
                                          <td> <table width="100%" border="0" cellspacing="1" cellpadding="1">
                                              <tr> 
                                                <td bgcolor="#FFFFFF"> <table width="100%" border="0" cellspacing="1" cellpadding="1">
                                                    <tr bgcolor="FFFFFF"> 
                                                      <td width="60" bgcolor="#FFCCFF"> <div align="center"><span class="style1"></span></div></td>
                                                      <td width="376" bgcolor="#FFCCFF"> <div align="left" class="style1"><strong>&#3594;&#3639;&#3656;&#3629;&#3585;&#3619;&#3632;&#3607;&#3641;&#3657;</strong></div></td>
                                                      <td width="102" bgcolor="#FFCCFF"> <div align="left" class="style1"><strong>&#3612;&#3641;&#3657;&#3605;&#3633;&#3657;&#3591;</strong></div></td>
                                                      <td width="122" bgcolor="#FFCCFF"> <div align="center" class="style1"><strong>Read/View</strong></div></td>
                                                    </tr>
                                                </table></td>
                                              </tr>
                                            </table>
                                            <?
						  

$select_type_ans ="select * from webboard_ans where idwb = '$id'";
$query_select2=mysql_query($select_type_ans);
$num_rows_ans=mysql_num_rows($query_select2);
if ($num_rows_ans >= 15)
{
$img_icon = "hot.gif";
}else{
$img_icon = "icon_board_default.gif";
}

$page = $_GET['page'];

$select_type="select * from webboard order by id desc";
$query_select=mysql_query($select_type);
$num_rows=mysql_num_rows($query_select);

if($num_rows<1){
echo "<br><br><center><b>ไม่พบข้อมูลใด ๆ ในฐานข้อมูลค่ะ</b></center>";
}else{

		$select="select * from webboard order by id desc";
		$q_ry = mysql_query($select);
	 	$num_rows=mysql_num_rows($q_ry);
  		$pagesize=25;
		$rt=$num_rows%$pagesize;
		if($rt!=0)
			{
				$totalpage=floor($num_rows/$pagesize)+1;
			}
		else
			{
				$totalpage=floor($num_rows/$pagesize);
				$toppic_id=1;
			}
		if(empty($page))
			{
				$page=1;
			}
		mysql_free_result($q_ry);
		$goto=($page-1)*$pagesize;
$sql_select_mem="Select * From webboard order by id desc limit $goto,$pagesize";
		$fect=mysql_query($sql_select_mem);
		if(!$fect)
		{
		("ติดต่อฐานข้อมูลไม่ได้".mysql_error());
		exit;
		}

	  $bgcount=0;
	while($rows=mysql_fetch_array($fect))
	{
$id =$rows['id'];
$topic =$rows['topic'];
$name =$rows['name'];
$photo1 =$rows['photo1'];
$read1 =$rows['read1'];
$dateregist =$rows['dateregist'];
$update_time = time();
$nameshow = substr($name,0,20);
$bgcount=$bgcount+1;
$bgmod=$bgcount%2;
if($bgmod==0){
	$bgcolor="#ffffff";
}else{
	$bgcolor="#ffffff";
}

$select_type_ans ="select * from webboard_ans where idwb = '$id'";
$query_select2=mysql_query($select_type_ans);
$num_rows_ans=mysql_num_rows($query_select2);
if ($num_rows_ans >= 15)
{
$img_icon = "<img src=images/hot01.gif width=31 height=31>";
}else{
$img_icon = "";
}
	?>
                                            <table width="100%" border="0" cellspacing="1" cellpadding="1">
                                              <tr> 
                                                <td width="62"> <div align="center"> 
                                                     <img src="images/icon_board_default.gif" width="16" height="16"></div></td>
                                                <td width="375"><a href=ShowThread.php?topicID=<? echo "$id"; ?>><? echo substr($topic,0,45)."..";?></a> 
                                                  <i>(<? echo "$dateregist"; ?>)</i></td>
                                                <td width="109"> <div align="left"><? echo "$nameshow"; ?></div></td>
                                                <td width="118"> <div align="center"><? echo "$read1"; ?> 
                                                    / 
                                                    <?
$select_type1 ="select * from webboard_ans where idwb = '$id'";
$query_select1=mysql_query($select_type1);
$num_rows_cs=mysql_num_rows($query_select1);
echo "<u>$num_rows_cs</u>";
?>
                                                    </div></td>
                                              </tr>
                                              <tr> 
                                                <td colspan="4"><div align="center"></div></td>
                                              </tr>
                                            </table></td>
                                        </tr>
                                        <tr> 
                                          <td> 
                                            <?
}
}
?>
                                            <br> </td>
                                        </tr>
                                      </table>
                                      <br> 
                                      <strong><span class="maekhawtom">&#3627;&#3609;&#3657;&#3634; 
                                      :</span></strong> <span> 
                                      <? 
	for($i=1;$i<$page;$i++)
	{
	echo"[<a href='$PHP_SELF?page=$i'>$i</a>]";
	}
	echo"[<b>$page</b>]";
	for($i=$page+1;$i<=$totalpage;$i++)
	{
	echo"[<a href='$PHP_SELF?page=$i'>$i</a>]";
	}
	?>
                                      </span></td>
                                  </tr>
                                </table>
                                <p>&nbsp;</p></td>
                            </tr>
                          </table>
                          <strong></strong></td>
                      </tr>
                    </table></td>
                </tr>
              </table></td>
          </tr>
        </table>
      </div></td>
   <td><img src="images/spacer.gif" width="1" height="25" border="0" alt=""></td>
  </tr>
</table><? include("footer.php");?>

</body>
</html>

T1KUS90T
  root-grov@210.1.60.28:~$