
ASP代码一行多列改为多行多列问题
现在的代码是一行五列,我想改成多行多列,要如何改,请高手帮忙改一下subArticleContent(intTitleLen)dimi,strTempi=0dowhile...
现在的代码是一行五列,我想改成多行多列,要如何改,请高手帮忙改一下
sub ArticleContent(intTitleLen)
dim i,strTemp
i=0
do while not rsArticle.eof
strTemp=""
strTemp= strTemp & "<table class='top_m_txt01' width=100% border=0 cellspacing=3 cellpadding=0>"
strTemp= strTemp & "<tr>"
strTemp= strTemp & "<td width=40% rowspan=7>"
strTemp= strTemp & "<div align=center><a href=ProductShow.asp?ArticleID=" & rsArticle("articleid") & ">"
fileExt=lcase(getFileExtName(rsArticle("DefaultPicUrl")))
if fileext="jpg" or fileext="bmp" or fileext="png" or fileext="gif" then
strTemp= strTemp & "<img border=0 src=" & rsArticle("DefaultPicUrl") & " width=130 height=110>"
else
if fileext="swf" then
end if
end if
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
strTemp= strTemp & "</td>"
strTemp= strTemp & "</tr><tr>"
strTemp= strTemp & "<td height=1 colspan=3 bgcolor=#CCCCCC></td>"
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
response.write strTemp
rsArticle.movenext
i=i+1
if i>=MaxPerPage then exit do
loop
end subng
%> 展开
sub ArticleContent(intTitleLen)
dim i,strTemp
i=0
do while not rsArticle.eof
strTemp=""
strTemp= strTemp & "<table class='top_m_txt01' width=100% border=0 cellspacing=3 cellpadding=0>"
strTemp= strTemp & "<tr>"
strTemp= strTemp & "<td width=40% rowspan=7>"
strTemp= strTemp & "<div align=center><a href=ProductShow.asp?ArticleID=" & rsArticle("articleid") & ">"
fileExt=lcase(getFileExtName(rsArticle("DefaultPicUrl")))
if fileext="jpg" or fileext="bmp" or fileext="png" or fileext="gif" then
strTemp= strTemp & "<img border=0 src=" & rsArticle("DefaultPicUrl") & " width=130 height=110>"
else
if fileext="swf" then
end if
end if
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
strTemp= strTemp & "</td>"
strTemp= strTemp & "</tr><tr>"
strTemp= strTemp & "<td height=1 colspan=3 bgcolor=#CCCCCC></td>"
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
response.write strTemp
rsArticle.movenext
i=i+1
if i>=MaxPerPage then exit do
loop
end subng
%> 展开
1个回答
展开全部
<%
sub ArticleContent(intTitleLen)
dim i,strTemp
i=0
do while not rsArticle.eof
strTemp=""
strTemp= strTemp & "<table class='top_m_txt01' width=100% border=0 cellspacing=3 cellpadding=0>"
strTemp= strTemp & "<tr>"
strTemp= strTemp & "<td width=40% rowspan=7>"
strTemp= strTemp & "<div align=center><a href=ProductShow.asp?ArticleID=" & rsArticle("articleid") & ">"
fileExt=lcase(getFileExtName(rsArticle("DefaultPicUrl")))
if fileext="jpg" or fileext="bmp" or fileext="png" or fileext="gif" then
strTemp= strTemp & "<img border=0 src=" & rsArticle("DefaultPicUrl") & " width=130 height=110>"
else
if fileext="swf" then
end if
end if
if i mod 2=0 then '这个意思是 每2列作为一行,可以自己改
response.Write "</tr><tr>"
end if
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
strTemp= strTemp & "</td>"
strTemp= strTemp & "</tr><tr>"
strTemp= strTemp & "<td height=1 colspan=3 bgcolor=#CCCCCC></td>"
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
response.write strTemp
rsArticle.movenext
i=i+1
if i>=MaxPerPage then exit do
loop
end subng
%>
sub ArticleContent(intTitleLen)
dim i,strTemp
i=0
do while not rsArticle.eof
strTemp=""
strTemp= strTemp & "<table class='top_m_txt01' width=100% border=0 cellspacing=3 cellpadding=0>"
strTemp= strTemp & "<tr>"
strTemp= strTemp & "<td width=40% rowspan=7>"
strTemp= strTemp & "<div align=center><a href=ProductShow.asp?ArticleID=" & rsArticle("articleid") & ">"
fileExt=lcase(getFileExtName(rsArticle("DefaultPicUrl")))
if fileext="jpg" or fileext="bmp" or fileext="png" or fileext="gif" then
strTemp= strTemp & "<img border=0 src=" & rsArticle("DefaultPicUrl") & " width=130 height=110>"
else
if fileext="swf" then
end if
end if
if i mod 2=0 then '这个意思是 每2列作为一行,可以自己改
response.Write "</tr><tr>"
end if
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
strTemp= strTemp & "</td>"
strTemp= strTemp & "</tr><tr>"
strTemp= strTemp & "<td height=1 colspan=3 bgcolor=#CCCCCC></td>"
strTemp= strTemp & "</tr>"
strTemp= strTemp & "</table>"
response.write strTemp
rsArticle.movenext
i=i+1
if i>=MaxPerPage then exit do
loop
end subng
%>
本回答被提问者采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询