|
|
|
ไม่ error ครับ แต่มันไม่ แบ่งหน้า ให้ครับ ขอบคุณล่วงหน้านะครับ |
|
|
|
|
|
|
|
รบกวนดูให้ทีนะครับ ว่าเป็นที่อะไร ครับ ถ้า ไม่เสีย เวลา มาก อยากให้ ช่วย อธิบายด้วยนะครับว่าทำไมถึงไม่ได้ ขอบคุณมากครับ
Code (PHP)
<?
// ปรับปรุงส่วนที่ 1
$page=$_GET[page];
if ($page=="") {
$page=1;
}
$each=5;
?>
<?
include "chksession.php";
?>
<!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><br />
<title>www.sabuyjung.net</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<link href="css/index.css" rel="stylesheet" type="text/css" />
<style>
Body{background-image:url(image/theme/bg3.png);background-position: center;background-repeat: no-repeat;background-attachment: fixed;background-color: color code;}.index #back1 {
background-image: url(image/back1.png);
}
</style>
<style type="text/css">
<!--
body {
background-color: #000000;
}
.index table {
}
#white {
background-color: #FFFFFF;
}
a:link {
text-decoration: none;
color: #000000;
}
a:visited {
text-decoration: none;
color: #000000;
}
a:hover {
text-decoration: none;
color: #FF0000;
}
a:active {
text-decoration: none;
color: #000000;
}
body,td,th {
font-size: 16px;
font-family: segoe ui, Arial, sans-serif;
}
#apDiv4 {
position:absolute;
left:455px;
top:458px;
width:587px;
height:602px;
z-index:4;
}
-->
</style>
<script src="Scripts/AC_RunActiveContent.js" type="text/javascript"></script>
<script type="text/javascript">
<!--
function MM_swapImgRestore() { //v3.0
var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}
function MM_preloadImages() { //v3.0
var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}
function MM_findObj(n, d) { //v4.01
var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
if(!x && d.getElementById) x=d.getElementById(n); return x;
}
function MM_swapImage() { //v3.0
var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
//-->
</script>
<link href="south-street/jquery-ui-1.8.10.custom.css" rel="stylesheet" type="text/css" >
<style type="text/css">
<!--
.style8 {font-family: "Layiji MaHaNiYom V1.5 OT"}
.style17 {font-family: "Sp Aftershock"}
.style18 {font-size: 36px}
.style23 {font-size: 18px}
.style30 {
color: #FF0000;
font-size: 16px;
}
.style34 {font-size: 16px; font-family: "segoe ui", Arial, sans-serif;}
.style35 {font-size: 14px}
.style38 {font-family: "segoe ui", Arial, sans-serif}
.style40 {font-size: 18px; font-weight: bold; }
.style42 {
font-size: 14px;
font-family: "segoe ui", Arial, sans-serif;
font-weight: bold;
}
.style44 {font-size: 24px}
.style45 {font-size: 16px; font-family: "segoe ui", Arial, sans-serif; font-weight: bold; }
.style48 {font-size: 14px; font-weight: bold; }
-->
</style>
</head>
<body onload="MM_preloadImages('image/bc1.1.png','image/bc2.1.png','image/bc3.1.png','image/bc4.1.png','image/bc5.1.png')">
<div align="center">
<table width="998" height="369" id="top">
<tr>
<td align="right" valign="bottom"><table width="726" height="145" border="0">
<tr>
<td><script type="text/javascript">
AC_FL_RunContent( 'codebase','http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0','width','733','height','47','src','top','quality','high','pluginspage','http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash','movie','top' ); //end AC code
</script><noscript><object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,28,0" width="733" height="47">
<param name="movie" value="top.swf" />
<param name="quality" value="high" />
<embed src="top.swf" quality="high" pluginspage="http://www.adobe.com/shockwave/download/download.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="733" height="47"></embed>
</object></noscript></td>
</tr>
</table></td>
</tr>
</table>
<table width="998" id="center">
<tr>
<td width="260" align="left" valign="top"><div align="center">
<table width="200" border="0">
<tr>
<td><iframe src="//www.facebook.com/plugins/likebox.php?href=http%3A%2F%2Fwww.facebook.com%2Fpages%2FSabuyjungnet%2F261545700537636&width=254&height=290&colorscheme=light&show_faces=true&border_color&stream=false&header=true" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:254px; height:290px;" allowTransparency="true"></iframe> </td>
</tr>
</table>
<p> </p>
</div> </td>
<td width="773" align="left" valign="top"><FORM METHOD="POST" ACTION="member/register2.php">
<table width="715" height="106" border="0">
<tr>
<td width="709" height="102" class="style35"><h1 class="style44">:: Sabuyjung.net::</h1>
<p class="style44">ยินดีต้อนรับคุณ <b>
<?=$sess_username?>
</b> ท่านกำลังอยู่ในระบบสมาชิก</p>
<h4>[ <a href="edit.php">แก้ไขข้อมูลส่วนตัว</a> ]
[ <a href="changepw.php">เปลี่ยนรหัสผ่าน</a> ]
[ <a href="guestion_form.php">ตั้งคำถามในกระทู้</a> ]
[ <a href="logout.php">ออกจากระบบ</a> ]</h4></td>
</tr>
</table>
<p align="center">
<?
include "connect.php";
include "function.php";
include "chksession.php";
// ปรับปรุงส่วนที่ 2
$sql="select * from tb_question";
$result=mysql_db_query($dbname,$sql);
$total=mysql_num_rows($result);
$totalpages=ceil($total/$each);
$goto = ($page-1)*$each;
$sql="select * from tb_question order by id_ques desc limit $goto,$each";
$result=mysql_db_query($dbname,$sql);
echo "
<table width='80%' border='0'>
<tr bgcolor='#D2E9FF'>
<td width='61%'> <center><b><font size='2' face='MS Sans Serif'>หัวข้อคำถาม</font></b></center></td>
<td width='15%'> <center><b><font size='2' face='MS Sans Serif'>ผู้ตั้งคำถาม</font></b></center></td>
<td width='16%'> <center><b><font size='2' face='MS Sans Serif'>ตั้งเมื่อวันที่</font></b></center></td>
</tr>";
while($record=mysql_fetch_array($result)) {
$id_ques=$record[id_ques];
$title_ques=$record[title_ques];
$detail_ques=$record[detail_ques];
$name_ques = $sess_username;
$email_ques=$record[email_ques];
$date_ques=$record[date_ques];
$title_ques=htmlspecialchars($title_ques);
$name_ques=htmlspecialchars($name_ques);
$detail_ques=nl2br(htmlspecialchars($detail_ques));
$date_ques=displaydate($date_ques);
echo "
<tr bgcolor='#FFFFFF'>
<td width='61%'> <font size='2' face='MS Sans Serif'><a href='answer_view.php?id_ques=$id_ques'>$title_ques</a></font></td>
<td width='15%'> <center><font size='2' face='MS Sans Serif'>$name_ques</font></center></td>
<td width='16%'> <center><font size='2' face='MS Sans Serif'>$date_ques</font></center></td>
</tr>";
} // end while
echo "</table>";
?>
<br />
<?php $ip=$_SERVER['REMOTE_ADDR'];
echo "<b><font face=\"MS Sans Serif\" size=\"1\" color=\"#000080\">IP Address ของคุณคือ $ip</font></b>"; ?><br />
</p>
</FORM><H1> </H1> </td>
</tr>
<tr>
<td colspan="2" align="left" valign="top"> </td>
</tr>
</table>
<br />
</body>
</html>
Tag : PHP
|
|
|
|
|
|
Date :
2012-01-11 20:45:55 |
By :
pee |
View :
980 |
Reply :
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ขอบคุณมากครับ
|
|
|
|
|
Date :
2012-01-11 21:59:46 |
By :
sabuyjung |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 02
|