<%@LANGUAGE="VBSCRIPT"%> <%OPTION EXPLICIT%> <%Response.Buffer = True%> <% Function SelectFilterItem(item) If Showing = item then SelectFilterItem = "selected" End If End Function '*** Dimension all the variables. Dim ViewLast, Showing Dim objRec Dim strSQL Dim LastHere 'Variables used for paging. Dim intCurrentPage, intCount '*** Open the database. Set objConn = Server.CreateObject ("ADODB.Connection") Set objRec = Server.CreateObject ("ADODB.Recordset") objConn.Open strconnect '*** The table headings, Topic, Author and so on can be used to order the messages (much like an email program) this is the code that does it. If Request.QueryString("orderby") <> "" then Session("OrderBy") = Request.QueryString("orderby") End If Select Case Session("Orderby") Case "Topic" objRec.Sort = "MessageTitle ASC" Case "Author" objRec.Sort = "MessageAuthor ASC" Case "Last+Post" objRec.Sort = "LastPost DESC" Case "Replies" objRec.Sort = "Replies DESC" Case Else objRec.Sort = "LastPost DESC" Session("OrderBy") = "Last Post" End Select objRec.cursorlocation=aduseclient StrSQL = "SELECT * FROM messages" If Request.Form("cboSearchType") = "Message Topics" OR Request.Form("cboSearchType") = "Message Authors" Then Session("txtSearchString") = Request.Form("txtSearchString") Session("cboSearchType") = Request.Form("cboSearchType") End If If Session("cboSearchType") = "Message Authors" Then StrSQL = StrSQL & " WHERE MessageAuthor LIKE '%" & Session("txtSearchString") & "%'" End If If Session("cboSearchType") = "Message Topics" Then StrSQL = StrSQL & " WHERE MessageTitle LIKE '%" & Session("txtSearchString") & "%'" End If objRec.Open strSQL, objConn, adOpenStatic, adLockReadOnly, adCmdText '*** Function to compare the date of the users last visit with the date of the last post. Function NewMessages(lpost) If datediff("s", LastHere, lpost) > 1 then NewMessages = MBImgNewMessage Else NewMessages = MBImgOldMessage End If End Function '*** Find out when the user was last here so that new messages can be highlighted. LastHere = Request.Cookies("aspmbuser")("Date") Response.Cookies("aspmbuser")("Date") = now() Response.Cookies("aspmbuser").Expires = Date + 30 '*** If they haven't been here before set the LastHere variable to a value that will highlight all messages as being new. if LastHere = "" then LastHere = dateadd("d",-10,now()) End if '*** Has the user just asked to view the messages updated in a certain time period? See select form field. If NOT Request.Form("days") = "" then ViewLast = Request.Form("days") '*** Write this value to the cookie so that next time the reload the page it will remain the same. Response.Cookies("aspmbuser")("ViewLast") = Request.Form("days") '*** If they haven't asked for a new time filter. Else '*** If there is no value in the cookie, show them all the messages. If Request.Cookies("aspmbuser")("ViewLast") = "" then ViewLast = "ALL" '*** Otherwise take the value from the cookie. Else ViewLast = Request.Cookies("aspmbuser")("ViewLast") End If End If Showing = ViewLast If Session("cboSearchType") = "" then If NOT ViewLast = "ALL" then '*** Subtract ViewLast amount of days from the current date. ViewLast = DateAdd("d",ViewLast, MediumDate(Date())) '*** Create a record set with only the fields from the last x days. objRec.Filter = "LastPost >= #" & MediumDate(ViewLast) & "#" End If End If %> <%=MBTitle%> <% '*** Print out the Body tag. Also a constant found in the config.inc file. Response.Write MBPageBody2 %>


<%=MBImgAddNew%>  <%=MBImgSearch%>


<% '*** The code above makes sure that the correct item in the drop-down box is highlighted. I'm certain that this was poor coding but it worked. '*** The section below prints the heading for the topics table. Notice the link URLs to order it. See above. Images are defined in the config.inc file. %> <% On Error Resume Next If Request.QueryString("page") = "" Then intCurrentPage = 1 Else intCurrentPage = CInt(Request.QueryString("page")) End If objRec.PageSize = MBPageSize If objRec.PageCount > 0 then objRec.AbsolutePage = intCurrentPage Else intCurrentPage = 0 End If Session("CurrentPage") = intCurrentPage Do While objRec.AbsolutePage = intCurrentPage And Not objRec.EOF %> <% objRec.MoveNext Loop '*** Yeah. It's the end of the table. Response.Write "
  <%=MBImgTopic%> <%=MBImgAuthor%> <%=MBImgLastPost%>


<%=NewMessages(objRec("LastPost"))%> <%=FONT1%>


<%=FONT1 & objRec("MessageAuthor")%> <%=FONT1%><%Call DisplayDateTime(objRec("LastPost"))%> <%=FONT1 & objRec("Replies")%>
" Response.Write "

" If objRec.PageCount > 1 then 'Print Previous Page if required If intCurrentPage <> 1 then Response.Write "Previous Page" Else Response.Write "Previous Page" End If 'Print direct access page numbers. For intCount = 1 to objRec.PageCount If intCount = 1 then Response.Write " | " End If If intCount = intCurrentPage then Response.Write intCount & " | " Else Response.Write "" & intCount & " | " End If Next 'Print Next Page if required If intCurrentPage <> objRec.PageCount then Response.Write "Next Page" Else Response.Write "Next Page" End If End If Response.Write "

Page " & intCurrentPage & " of " & objRec.PageCount & _ " | Ordered By: " & Session("orderby") & " | Showing: " Select Case Showing Case "-0" Response.Write "Topics updated today." Case "-1" Response.Write "Topics updated in the last 2 days." Case "-4" Response.Write "Topics updated in the last 5 days." Case "-9" Response.Write "Topics updated in the last 10 days." Case "-29" Response.Write "Topics updated in the last 30 days." Case "-99" Response.Write "Topics updated in the last 100 days." Case "ALL" Response.Write "All topics." End Select Response.Write "" If NOT Session("cboSearchType") = "" Then Response.Write "

Searched for: " & Session("txtSearchString") & "
On: " & Session("cboSearchType") & "
" Response.Write "Remove Search Filter" End If Response.Write "

" '*** Have a tidy. Don't want any of those nast memory leaks. objRec.Close objConn.Close Set objRec = Nothing Set objConn = Nothing %>

finkelhor sexual life events inventory

wide range


customer service

v tunnle

Italian wines

machinist sample resumes

into one with the help

myra levine nursing

internet marketing

mga produkto ng rehiyon 4

good way

willowbrook dinner movie

Scuola Leonardo

vivid verbs list

and its writer was

siouxland better jobs

website links

vcop game free installer

would like

barbie co m

ten minutes

solsgirth house

high school

kylie alsscan

exhibitions group

norinco m14 stocks

people like

adams funeral home marlin tx

behavior scientific

ass close up pps

pretty good

tara spencer nairn nude downloadsd

decisions; in particular

colonial recipes for home remedies

luxury car

pork chop cooking recipes

as diverse as criminal

permisos para trocas para mexico

search engines

traditional newfoundland recipes baked beans

to an annoyance

brent everett parole officer making video

finger around


went straight

vanilla butternut pound cake recipe

RSS feeds

yeast free diet recipes

boarding school

outback steak house ranch dressing recipe

online business

tube yuo

credit card

cici s enid

The word economics

converse how to customized

which they brought back.

abecedario azteca

remain intact

vitamin c graduation music video

Torres Strait

senarai tuntutan hindraf

wedding invitations

ky bt100 bluetooth adapter

latent heat

magdalena tina spermswap

web server

remote overhead door model 456

good chance

tied up crossdressers

absolutely to

sountrack of sana maulit muli

such cases

hdaudio softv92 smartcp

thought of as emitting

apologize timberland ft one republic lyrics

local real

recipe bagara baingan

hair growth

okinawa donut recipe

but rather a belief

revista don juan

free website

ninhydrin protein detection test sensitivity

high school

bill kaulitz

corn compare poem

lugaru registration code

local community

solo tangas

good condition

jingle bell rock kareoke

careful to make

chu hi recipe

insurance online

apurva agnihotri and shilpa

Shih Tzu

select electronics howard lurie

said Lisa

recipe for homemade buns

birth control

incinerate a sugar cube

of her by a friend

manishevitz foods

at times seemingl

mounting antlers how to

community service

cathy baker hee haw

should help


the Phinuit control

zila bakarin

could easily

marlene reid centre coalville

CarFax report

shaving pubes men

well over

keygen zone alarm

Australia Act

blue merle dachshund

integrate Multiple

panatone recipe

credit card

north santa tracer

eligibility requirements

hilary duffnude

designer prom

tallahassee theater imax schedule

search engine

dell car computer

and never having

northindian food

way back

qualifications for food stamps ohio

by simple consideration

male solo masterbation

weight loss

cranberry jam free recipe

low-divergence beam

atk lydia archives

wedding invitations

itzel garcia

dog training

repossesed cars for sale

high school

homemade cheesecake recipe

birth control

pickling eggs recipes

who advocate

gambar gambar payudara

John Dewey

achilles reflex arc

Roman Empire

years spent cold

watching satellite

2007 little sturgis ky pics

control panel

na3po4 reacts with hcl to produce

to believe

index of anna ancenis

Angst appears

tony alessandrini delaware

fuck hole

medieval gameball

search engine

labra tar pits

auto financing

madam loreen on horseback

Automotive Technology

recipe for neck bones

arrangements online

ancianos follando

carpal tunnel

easy pork tenderloin recipe

table lamp

vitamin c herbal douche abortion

automatic email

century arms ultra 87

whilst Kath

george foreman rotisserie cooking times

British settlement

layered alcohol drinks

reference to the grunge

dci blue coats

good deal

karen dream zipsets

sons cock


different ways

wachovia counterfeit official checks

who had preceded

making homemade raccoon traps

sexual harassment

anna ohura on the subway

sucked him

foods high in progesterone

bottled water