⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 show_shop.php

📁 LOVESTUdio多校园网络店铺 VER 3.0基于2.0开发
💻 PHP
📖 第 1 页 / 共 2 页
字号:
</tr>
<?php
}
?>
<tr>
     <td align="right" colspan="3"><?php echo $showpage; ?>&nbsp;&nbsp;</td>
  </tr>
</table>

<?php
}elseif($_GET[action]==ann){

$sql = "SELECT * FROM ".$tablepre."shopann WHERE  annowner= '$arr[shopowner]' ORDER BY annid DESC";
$res = $conn->query($sql);
$total = 0;
while($agr = $result->fetch_assoc()){
$total++;
}         
               $page = new ShowPage;   
               $page->PageSize = 5;   
               $page->Total = $total;   
               $page->LinkAry = array();                    
               $showpage = $page->ShowLink();

$res = $conn->query("SELECT * FROM ".$tablepre."shopann WHERE  annowner= '$arr[shopowner]' ORDER BY shannid DESC LIMIT ".$page->OffSet());

?>
<table width="100%" border="1" bordercolor="#F5EFEA" cellpadding="4" cellspacing="0">
<tr align="center">
<td width="7%">序号</td>
<td width="67%">公告标题</td>
<td width="26%">发表时间</td>
</tr>
<?php
while($aer = $res->fetch_assoc()){
?>
<tr>
<tD align="center"><?php echo $aer[shannid]; ?></tD>
<td>&nbsp;&nbsp;<a href="show_mation.php?action=shann&shannid=<?php echo $aer[shannid] ?>" target="_blank"><?php echo $aer[shanntitle]; ?></a></td>
<td align="center"><?php echo $aer[shanntime]; ?></td>
</tr>
<?php
}
?>
<tr>
     <td align="right" colspan="3"><?php echo $showpage; ?>&nbsp;&nbsp;</td>
  </tr>
</table>
<?php
}
?>


</td>
</tr>
</table>
</td>
<td background="skin/smallpic/ta_r.gif"></td>
</tr>
<tr>
<td><img src="skin/smallpic/ta_bl.gif" /></td>
<td background="skin/smallpic/ta_b.gif"></td>
<td><img src="skin/smallpic/ta_br.gif" /></td>
</tr>
</table>
</td>
</tr>
</table>
<table>
<tr>
<td height="5"></td>
</tr>
</table>
<table align="center" width="964" cellpadding="0" cellspacing="">
<tr>
<td>
<table class="tableline" width="100%" cellpadding="4" cellspacing="0">
<tr>
<td width="244">评论</td>
<td width="706" align="right">发表评论</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0">
<tr><td height="5">
</td></tr>
</table>
<?php
$rest = $conn->query("SELECT * FROM ".$tablepre."msword WHERE msshop='$_GET[shopid]'");
$total = 0;
while($adr = $rest->fetch_assoc()){
$total++;
}          
               $page = new ShowPage;   
               $page->PageSize = 10;   
			   $page->mode = "shopid=".$_GET[shopid]."&";
               $page->Total = $total;   
               $page->LinkAry = array();                    
               $showpage = $page->ShowLink();

$rest = $conn->query("SELECT * FROM ".$tablepre."msword WHERE msshop='$_GET[shopid]' ORDER BY msid ASC LIMIT ".$page->OffSet());
$k = $_GET[page];
if($k == "") $k=1;
$i = 10*($k-1)+1;  
				  

while($aor = $rest->fetch_assoc()){
?>
<table class="tableline" width="100%" cellpadding="0" cellspacing="0">
<tr>
<td width="244" height="200">
<table height="100%" style='table-layout:fixed' bgcolor="#F5EFEA" width="100%" cellpadding="0" cellspacing="0">
<tr>
<td height="20"></td>
</tr>
<tr>
<td align="center" valign="top">
<?php
if($aor[msowner] == vistor){
   echo "<table width='80' height='80' cellpadding='0' cellspacing='0'>
         <tr><td align='center'>
		 <img src='skin/mashead/".$aor[mshead]."' border='0' onload='DrawImage(this,80)' style='display:none' />
		</td></tr></table>
         <font color='red'>游客</font><br />";  		 
                           }
else {     echo "<img src='skin/heads/".$aor[mshead]."' /><br /><font color='red'>注册用户</font><br />";
}
   echo $aor[msname];
   echo "<br />";
   echo "性别:";
   echo selectsex($aor[mssex]);
?>

</td>
</tr>
</table>
</td>
<td width="706" valign="top">
<table width="100%" cellpadding="4" cellspacing="0">
<tr height="25">
<td width="6%" background="skin/hrs.gif">
<img src="skin/face/<?php echo $aor[msface]; ?>.gif" /></td>
<td width="83%" background="skin/hrs.gif">
发表时间: <?php echo $aor[mstime]; ?></td>
<td width="3%" background="skin/hrs.gif">
<?php
if($aor[msowner] == vistor){
    echo "<img src='skin/yk.gif' />";
}
else{  echo "<img src='skin/hy.gif' />"; }
?></td>
<td width="8%" align="right" background="skin/hrs.gif"><?php echo $i; ?>楼</td>
</tr>
<tr>
<td colspan="4"><br /><?php echo $aor[mstext]; ?></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellpadding="0" cellspacing="0">
<tr><td height="5">
</td></tr>
</table>
<?php
$i++;
}
?>
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td align="right"><?php echo $showpage; ?>&nbsp;&nbsp;</td>
</tr>
</table>
<form name="myform" action="chk_ms.php" method="post">
<table border="1" style="border-collapse:collapse" bordercolor="#CCCCCC" width="100%" cellpadding="4" cellspacing="0">
<tr>
<td colspan="3" align="center">发表评论</td>
</tr>
<?php
if(empty($_SESSION['username'])){
?>
<tr>
<td width="10%" align="right">你的呢称:</td>
<td colspan="2"><input name="petname" size="15" maxlength="30" class="input0"></td>
</tr>
<tr>
<td align="right">性别:</td>
<td colspan="2">
<select name="sex">
       <option value="">请选择</option>
	   <option value="0">男</option>
	   <option value="1">女</option>
 </select>
</td>
</tr>
<?php
}
?>
<tr>
<td align="right">头像&amp;表情:</td>
<td width="13%" align="center">
<?php
if(!empty($_SESSION['username'])){
                $userhead = checklei($_SESSION['username'],$tablepre.user,username,userhead);                echo "<img src='skin/heads/".$userhead."' /><input type='hidden' name='myhead' value='".$userhead."'>"; 
								 }
else{								 
?>
<div id="imgBox"><!--这里是图片下拉选择器的位置--></div>
<input name="myhead" type="hidden" id="myface" size="10" value="">
<script language="JavaScript">
<!--
var imgWidth=64; 
var imgHeight=64; 
var imgSrc="skin/mashead/数字序号.gif"; 
var selectedNo=1; 
var selecteSize=5; 



var myHTML='<SPAN onmouseover="isin=true" onmouseout="isin=false">';
myHTML+='<table width="1" onclick="showlist(this)" title="选择提示框" border="0" cellspacing="0" cellpadding="0"><tr><td><img name="imgselected" border=1 src="'+imgSrc.replace("数字序号",selectedNo)+'" WIDTH='+(imgWidth)+' HEIGHT='+imgHeight+'></td><td valign=top><img src="skin/smallpic/33.gif" /></td></tr></table>';
myHTML+='<div onscroll="scrollud()" id="imgBox" \n';
myHTML+='style="position:absolute;left=-800;top=0;background-color:#FFFFFF;border: 1px solid #000000;overflow-x:hidden;overflow-y:scroll; width:'+(imgWidth+20)+'px; height: '+imgHeight*selecteSize+'px">';
for(i=1;i<13;i++){
myHTML+="<img listID="+i+" src='"+imgSrc.replace("数字序号",i)+"' alt='"+imgSrc.replace("数字序号",i)+"' width="+imgWidth+" height="+imgHeight+" onclick='selectme(this)' onload='if(init)init()'><br />";
}
myHTML+= "</div></SPAN>";
imgBox.outerHTML=myHTML;


function showlist(obj){

if(imgBox.style.pixelLeft!=-800){imgBox.style.pixelLeft=-800; return;}



var mytop=obj.offsetTop; 
var myleft=obj.offsetLeft;
 
while(obj=obj.offsetParent){
myleft+=obj.offsetLeft; 
mytop+=obj.offsetTop; 
}

imgBox.style.left=myleft;
imgBox.style.top=mytop+imgHeight+2;

}

var isin=false;
function selectme(obj){ 
if(!isin||obj){imgBox.style.pixelLeft=-800;} 
if(obj){

myform.myhead.value=imgSrc.replace("数字序号",obj.listID);
document.images["imgselected"].src=imgSrc.replace("数字序号",obj.listID);
}
}

var mytime=setTimeout("",0);
var pre_X=0; 
function scrollud(){ 
var current_X=imgBox.scrollTop; 

if(current_X>pre_X && imgBox.scrollTop< Math.ceil(imgBox.scrollTop/imgHeight)*imgHeight){
clearTimeout(mytime);
mytime=setTimeout("imgBox.scrollTop=Math.round(imgBox.scrollTop+1);",1);
}
else if(current_X<pre_X && imgBox.scrollTop> Math.floor(imgBox.scrollTop/imgHeight)*imgHeight){
clearTimeout(mytime);
mytime=setTimeout("imgBox.scrollTop=Math.round(imgBox.scrollTop-1);",1);
}
pre_X=current_X;
}
function init(){ 
imgBox.scrollTop=selectedNo*imgHeight;
myform.myhead.value=imgSrc.replace("数字序号",selectedNo);
}
myActivation="selectme(null)";
if(document.body.onclick)
{
eval(document.body.onclick.toString().replace('anonymous()','bodyclick()'));
document.body.onclick=new Function("bodyclick();"+myActivation);
}
else document.body.onclick=new Function(myActivation);
-->
</script>
<?php
}
?>
</td>
<td width="77%" valign="bottom">
<input type="radio" name="face" value="1" checked="checked">
<img src="skin/face/1.gif" />
<?php
for($i=2;$i<21;$i++){
echo "<input type='radio' name='face' value='".$i."'><img src='skin/face/".$i.".gif' />";
if($i==10) echo "<br />";
 }
?></td>
</tr>
<tr>
<td align="right">评论内容:</td><td colspan="2"><iframe id="eWebEditor1" src="edit/wordeditor.htm?id=msnr&fullscreen=" frameborder="0" scrolling="no" width="700" height="200"></iframe> 
<textarea cols="60" rows="10" style="display:none" name="msnr" id="msnr" ></textarea></td>
</tr>
<tr>
<td colspan="3" align="center">
<input type="hidden" name="msshop" value="<?php echo $_GET[shopid]; ?>">
<input type="hidden" name="message" value="msword">
<input type="submit" name="submit" class="input1" value="发表"></td>
</tr>
</table>
</form>
</td>
</tr>
</table>
<?php
require_once('pagetag/bottommation.php'); 
$conn->close();
?>
</body>
</html>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -