|
|
|
| DATE & TIME |
|
EVENTS |
|
|
|
<%
' Define our connection object
dim strConn, cxn, rst
dim mdbPath
dim strSelect
' initial connection info
mdbpath=Server.MapPath("/toronto/mdb/ncuto.mdb")
strConn="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & mdbPath
strSelect="select * from info where info_type like '2%' and " &_
" start_date < #" & now() & "# order by start_date, city"
' get connection
set cxn = Server.CreateObject("ADODB.Connection")
cxn.CommandTimeout = 15
cxn.ConnectionTimeout = 30
cxn.Open strConn
' execute query
Set rst = cxn.Execute (strSelect, , adCmdText)
do while not rst.EOF
eventsDate = rst.fields("start_date").value
eventsTitle = rst.fields("title").value
eventsSummary = rst.fields("summary").value
eventsLink = rst.fields("link").value
detail = rst.fields("detail").value
%>
| <%Response.Write(eventsDate) %> |
|
<%Response.Write(eventsTitle) %>
<%Response.Write(eventsSummary) %>
<%
If (detail = "Y") Then
%>
more...
<%
End if
%>
|
|
|
|
<%
' move to the next record
rst.MoveNext
loop
' release db resource
rst.Close
cxn.Close
Set rst = nothing
Set cxn = nothing
%>
|
|
|
|
|
 |
|
|
 |
|
|
|
|
|
|