当前位置:编程学习 > asp >>

asp的一些简单问题关于整除的

<!--#include file="sub/conn.asp" -->

<!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>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312" />
<title>无标题文档</title>
<style type="text/css">
<!--
@import url("images/css.css");
body {
 margin-left: 0px;
 margin-top: 0px;
 margin-right: 0px;
 margin-bottom: 0px;
}
-->
</style>
</head>

<body>
<table width="200" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td><form id="theform" name="theform" method="post" action="">
      <table width="759" height="623" border="0" align="center" cellpadding="0" cellspacing="0">
        <tr>
          <%
       sql="select * from desk where type='1' order by id asc"
       set rs=conn.execute(sql)
      i=1
      if not rs.eof then
      for i=1 to rs.eof
      %>
          <td width="759" height="151" align="left" valign="top"><table width="151" height="151" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td width="151">
                    <img src="<%=rs("desk_images")%>" width="152" height="100" border="0" /></td>
              </tr>
          </table>
            </td>
          <%
      if not (i mod 4)=0 then
      i=i+1
      rs.movenext
         else
         response.write("<br>")
         end if
         next
     
      else
      response.Write("满座,没有空桌子")
      end if
      %>
        </tr>
      </table>
        </form>
    </td>
  </tr>
</table>
</body>
</html>

 

不知道为什么,出来的页面是白花花的,没有东西

答案:     <%
       sql="select * from desk where type='1' order by id asc"
       set rs=conn.execute(sql)
       if not rs.eof then
     i=1
   do while not rs.eof
      %>
          <td width="759" height="151" align="left" valign="top">
     <table width="151" height="151" border="0" cellpadding="0" cellspacing="0">
              <tr>
                <td width="151">
                    <img src="<%=rs("desk_images")%>" width="152" height="100" border="0" /></td>
              </tr>
           </table>
           </td>
     <%
        if (i mod 4)=0 then   response.write("</tr>")
   i=i+1
   rs.movenext
        loop
      else
       response.Write("满座,没有空桌子")
      end if
      %>

 

 

记得给我个满意答案啊!我都好久没来这问问了...不要说不知道是那个答的啊!一直匿名回答

晴天打雨伞

。肯定是图片不存大,你换些内容显示。我都可以显示。

上一个:ASP和ASP.NET有什么区别
下一个:ASP页面中的一个javascript的Function函数

CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,