一个asp程序排版的问题请求支援
解决时间 2021-05-10 13:44
- 提问者网友:锁深秋
- 2021-05-09 14:38
我想把截图中左下方的"常见问题"放到它上面的"常见问题"的右边,代码我贴出来,请帮忙看看,谢谢回答的各位朋友.
<div class="body" >
<table cellpadding="0" cellspacing="0">
<tr>
<td>
<!--常见问题-->
<div class="box3" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
<!--常见问题-->
<div class="box4" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
</td>
<td >
</td>
<td >
<!--#include file="right.asp" -->
</td>
</tr>
</table>
</div>
最佳答案
- 五星知识达人网友:七十二街
- 2021-05-09 15:48
<div class="body" >
<table cellpadding="0" cellspacing="0">
<tr>
<td>
<!--常见问题-->
<div class="box3" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
<!--常见问题-->
<div class="box4" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
</td>
<td >
</td>
<td >
<!--#include file="right.asp" -->
</td>
</tr>
</table>
</div>
就上面那两行改过:
<div class="box3" >
<div class="box4" >
定位层浮动属性为左就可以了
全部回答
- 1楼网友:行路难
- 2021-05-09 18:29
你看下是这样吗?
<div class="body" >
<table cellpadding="0" cellspacing="0">
<tr>
<td>
<!--常见问题-->
<div class="box3" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
<!--常见问题-->
</td>
<td >
</td>
<td ><div class="box4" >
<table cellpadding="3" cellspacing="0" class="box_title">
<tr>
<td class="box_title_td01">
常见问题</td>
<td class="box_title_td02">
</td>
</tr>
</table>
<% set rs=news.load("top 11","where n.smallclassid=24","order by n.id desc") %>
<div >
<% do while not rs.eof %>
* <a href="shownews.asp?id=<%=rs.fields("id") %>" target="_blank" class="b"><%=left(rs.fields("title"),18) %></a><br />
<% rs.movenext:loop %>
</div>
<% rs.close:set rs=nothing %>
</div>
<!--#include file="right.asp" -->
</td>
</tr>
</table>
</div>
- 2楼网友:旧脸谱
- 2021-05-09 17:02
用层了干嘛搞那么多表格。
box3 box4不知道你写的什么样式?
这里你可以直接把外层的div去掉,直接把那个表格拆分成两列就可以了啊?
用层的话你用float属性控制一下
我要举报
大家都在看
推荐资讯