<% Set DbCon=Server.CreateObject("ADODB.Connection") Set RS=Server.CreateObject("ADODB.RecordSet") DbCon.Open("DSN=ch71;UID=sa;PWD=pages30") RS.Open("Select * from board01 Order By no Desc"),DbCon,1,1 sql="select count(*) as tc from board01" Set rs1 = DbCon.Execute(sql) if rs1("tc")=0 then %>
  ¾ÆÁ÷ µî·ÏµÈ ³»¿ëÀÌ ¾ø½À´Ï´Ù
<%else %> <% if rs1("tc") < 5 then RS.PageSize=rs1("tc") RowCount=rs.PageSize Do While Not RS.EOF and RowCount >0 ss="select convert(char(23),subject) as sub from board01 where no="&rs("no") set rr=dbcon.Execute(ss) %> <% RowCount = RowCount-1 RS.MoveNext Loop DbCon.Close set rs=nothing set DbCon=nothing %>
')" class="cen"><%=rr("sub")%>..
<% else %> <% RS.PageSize=4 RowCount=rs.PageSize Do While Not RS.EOF and RowCount >0 %> <% RowCount = RowCount-1 RS.MoveNext Loop DbCon.Close set rs=nothing set DbCon=nothing %>
dot.gif (65 bytes) " class="cen"><%=rr("sub")%>..
<% end if end if %>