日期:2014-05-17  浏览次数:20870 次

请求高手帮忙删除未填信息行,谢谢大家。。。。。。。
1.htm
<tr>
<td> <input   type   =   "text "   name   =   "text1 "   id= "t1 "   > text1
<td> <input   type   =   "text "   name   =   "text2 "   id= "t2 "   > text2
<td> <input   type   =   "text "   name   =   "text3 "   id= "t3 "   > text3
<tr>
<input   type   =   "submit "   value   =   "preview "   name   =   "B1 ">
2.asp
<%   text1   =   request.form( "t1 ")   %>
<%   text2   =   request.form( "t2 ")   %>
<%   text3   =   request.form( "t3 ")   %>
<br> <%   =   text1   %>
<br> <%   =   text2   %>
<br> <%   =   text3   %>

怎样修改代码才能让没有填过的text文本框不占用一行空行啊。

------解决方案--------------------
<% if request.form( "t1 ") <> " " Response.Write( " <br /> &request.form( "t1 ") ") end if %>
<% if request.form( "t2 ") <> " " Response.Write( " <br /> &request.form( "t2 ") ") end if %>
<% if request.form( "t3 ") <> " " Response.Write( " <br /> &request.form( "t3 ") ") end if %>