%@LANGUAGE="VBSCRIPT"%>
<%
Dim rcdPosts__varID
rcdPosts__varID = "11"
if (Request.QueryString("PostID") <> "") then rcdPosts__varID = Request.QueryString("PostID")
%>
<%
set rcdPosts = Server.CreateObject("ADODB.Recordset")
rcdPosts.ActiveConnection = MM_Discussion_STRING
rcdPosts.Source = "SELECT * FROM tblPosts WHERE numPostID = " + Replace(rcdPosts__varID, "'", "''") + " ORDER BY txtDateOfPost DESC"
rcdPosts.CursorType = 0
rcdPosts.CursorLocation = 2
rcdPosts.LockType = 3
rcdPosts.Open()
rcdPosts_numRows = 0
%>
<%
set rcdReply = Server.CreateObject("ADODB.Recordset")
rcdReply.ActiveConnection = MM_Discussion_STRING
rcdReply.Source = "SELECT * FROM tblReply ORDER BY txtDateOfReply DESC"
rcdReply.CursorType = 0
rcdReply.CursorLocation = 2
rcdReply.LockType = 3
rcdReply.Open()
rcdReply_numRows = 0
%>
<%
' *** Recordset Stats, Move To Record, and Go To Record: declare stats variables
' set the record count
rcdPosts_total = rcdPosts.RecordCount
' set the number of rows displayed on this page
If (rcdPosts_numRows < 0) Then
rcdPosts_numRows = rcdPosts_total
Elseif (rcdPosts_numRows = 0) Then
rcdPosts_numRows = 1
End If
' set the first and last displayed record
rcdPosts_first = 1
rcdPosts_last = rcdPosts_first + rcdPosts_numRows - 1
' if we have the correct record count, check the other stats
If (rcdPosts_total <> -1) Then
If (rcdPosts_first > rcdPosts_total) Then rcdPosts_first = rcdPosts_total
If (rcdPosts_last > rcdPosts_total) Then rcdPosts_last = rcdPosts_total
If (rcdPosts_numRows > rcdPosts_total) Then rcdPosts_numRows = rcdPosts_total
End If
%>
<%
' *** Recordset Stats: if we don't know the record count, manually count them
If (rcdPosts_total = -1) Then
' count the total records by iterating through the recordset
rcdPosts_total=0
While (Not rcdPosts.EOF)
rcdPosts_total = rcdPosts_total + 1
rcdPosts.MoveNext
Wend
' reset the cursor to the beginning
If (rcdPosts.CursorType > 0) Then
rcdPosts.MoveFirst
Else
rcdPosts.Requery
End If
' set the number of rows displayed on this page
If (rcdPosts_numRows < 0 Or rcdPosts_numRows > rcdPosts_total) Then
rcdPosts_numRows = rcdPosts_total
End If
' set the first and last displayed record
rcdPosts_first = 1
rcdPosts_last = rcdPosts_first + rcdPosts_numRows - 1
If (rcdPosts_first > rcdPosts_total) Then rcdPosts_first = rcdPosts_total
If (rcdPosts_last > rcdPosts_total) Then rcdPosts_last = rcdPosts_total
End If
%>
<%
' *** Go To Record and Move To Record: create strings for maintaining URL and Form parameters
' create the list of parameters which should not be maintained
MM_removeList = "&index="
If (MM_paramName <> "") Then MM_removeList = MM_removeList & "&" & MM_paramName & "="
MM_keepURL="":MM_keepForm="":MM_keepBoth="":MM_keepNone=""
' add the URL parameters to the MM_keepURL string
For Each Item In Request.QueryString
NextItem = "&" & Item & "="
If (InStr(1,MM_removeList,NextItem,1) = 0) Then
MM_keepURL = MM_keepURL & NextItem & Server.URLencode(Request.QueryString(Item))
End If
Next
' add the Form variables to the MM_keepForm string
For Each Item In Request.Form
NextItem = "&" & Item & "="
If (InStr(1,MM_removeList,NextItem,1) = 0) Then
MM_keepForm = MM_keepForm & NextItem & Server.URLencode(Request.Form(Item))
End If
Next
' create the Form + URL string and remove the intial '&' from each of the strings
MM_keepBoth = MM_keepURL & MM_keepForm
if (MM_keepBoth <> "") Then MM_keepBoth = Right(MM_keepBoth, Len(MM_keepBoth) - 1)
if (MM_keepURL <> "") Then MM_keepURL = Right(MM_keepURL, Len(MM_keepURL) - 1)
if (MM_keepForm <> "") Then MM_keepForm = Right(MM_keepForm, Len(MM_keepForm) - 1)
' a utility function used for adding additional parameters to these strings
Function MM_joinChar(firstItem)
If (firstItem <> "") Then
MM_joinChar = "&"
Else
MM_joinChar = ""
End If
End Function
%>
ED CRAIGS TIG - MIG
WELDING FORUM
. www.weldreality.com.
The world's largest website
on MIG - Flux Cored - MIG Welding
TIP TIG Welding is 2 to 10 times faster than TIG
with superior quality than TIG - MIG - FCAW.
Discussion
Group Contents
This
discussion group is intended for legitimate weld-related questions and content.
In no way is this discussion group an avenue for welding industry sales persons
to generate sales leads, so please refrain from any solicitations on weldreality.com.