|
|
|
|
|
<%=newstitle%>
<%
if not IsNumeric(show_stories) then
show_stories = "999"
end if
Set dConn = Server.CreateObject("ADODB.Connection")
dConn.Open "PROVIDER=MICROSOFT.JET.OLEDB.4.0;DATA SOURCE=" & database_path
strSQL = "SELECT TOP " & show_stories & " expire, id, newsdate, newstitle, newsbody from tblnews where active = 1 and #" & todaydate & "# < expire order by newsdate desc, id;"
'response.write strSQL
Set newsRS = Server.CreateObject("ADODB.recordset")
newsRS.Open strSQL, dConn, 1, 3
recordcount = newsRS.recordcount
if recordcount < 1 then
newsRS.Close
Set newsRS = Nothing
response.write(errormsg2 & loginlink)
response.end
end if
data = newsRS.GetRows()
'Data is retrieved so close all connections
newsRS.Close
Set newsRS = Nothing
dconn.close
Set dconn = nothing
'Setup for array usage
iRecFirst = LBound(data, 2)
iRecLast = UBound(data, 2)
%>
<%
' Loop through the records (second dimension of the array)
For I = iRecFirst To iRecLast
news_expire = data(0,I)
news_id = data(1,I)
news_dat = data(2,I)
news_title = data(3,I)
news_body = data(4,I)
response.write "" & _
"| " & news_title & " " & news_dat & " | " & _
" " & _
"" & _
"| " & news_body & " | " & _
" "
Next ' I
%>
| admin | webmaster@hookandhatchet.co.uk |
|
|
|