% '----------General section------------ CURRENT_VERSION = ("0") CURRENT_STYLE = ("../Default_Style.css") FormAction = ("Guest_Book.asp") ScriptRelativeFolder = ("CGI_BIN") pos=InstrRev(LCase(Request.ServerVariables("PATH_TRANSLATED")),LCase(ScriptRelativeFolder) & "\" & LCase(FormAction)) BS_Root = Left(Request.ServerVariables("PATH_TRANSLATED"), pos-1 ) DB_Path =BS_Root & "\" ScriptFolderAddress =BS_Root & "\" & ScriptRelativeFolder & "\" URL =Request.ServerVariables("URL") SERVER_NAME=Request.ServerVariables("SERVER_NAME") ScriptAbsoluteUrl="http://"&SERVER_NAME&URL ScriptRelativeFolder = ("CGI_BIN") pos=InstrRev(LCase(ScriptAbsoluteUrl),LCase(ScriptRelativeFolder) & "/" & LCase(FormAction)) BS_Root_URL = Left(ScriptAbsoluteUrl, pos-1) CurrentFolder = BS_Root_URL &ScriptRelativeFolder& "/" bHeaderFired = FALSE 'Enumeration Of Shipping Payment Methods '==========Enumeration Of Payment Methods============= FRSC = 1 'Flat rate shipping cost CPI = 2 'Cost per item FRPW = 3 'Fixed rate per weight (Kg or lb.) POFS = 4 'Percentage of sales '==========Constants============= '---- CursorTypeEnum Values ---- Const adOpenForwardOnly = 0 Const adOpenKeyset = 1 Const adOpenDynamic = 2 Const adOpenStatic = 3 '---- LockTypeEnum Values ---- Const adLockReadOnly = 1 Const adLockPessimistic = 2 Const adLockOptimistic = 3 Const adLockBatchOptimistic = 4 '=========End of Section=========== '----------Parameters section------------ Parameter_1 = Request("GuestName") if Request("GuestName")= "" Then Parameter_1 = "" 'Default value else if Request("GuestName").Count = 1 then Parameter_1 = Request("GuestName") end if end if Parameter_2 = Request("GuestEmail") if Request("GuestEmail")= "" Then Parameter_2 = "" 'Default value else if Request("GuestEmail").Count = 1 then Parameter_2 = Request("GuestEmail") end if end if Parameter_3 = Request("GuestComments") if Request("GuestComments")= "" Then Parameter_3 = "" 'Default value else if Request("GuestComments").Count = 1 then Parameter_3 = Request("GuestComments") end if end if '----------Variables section------------ Dim VarArray(0,0) VarNum = 1 'Initialization of Vars Variable_4 = "mailto:" 'Initial value 'Subroutins and functions Sub PushVars() VarArray(0,0)=Variable_4 end sub Sub PopVars() end sub Sub RestoreVars() Variable_4=VarArray(0,0) end sub 'Functions that in the future should be placed in stanalone .INC File 'Function to format date string Function format_date(date,dataformat) months =Array("January","February","March","April","May","June","July","August","September","October","November","December") mon = Array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec") 'dd-MMM-yyyy = 0 'MM/dd/yyyy = 1 'dd MMMM,yyyy = 2 'MMMM dd,yyyy = 3 daypart = Day(date) monthpart = Month(date) yearpart = Year(date) monthpart = monthpart -1 if(dataformat = 0) then format_date = daypart & " " & mon(monthpart) & "," & yearpart end if if(dataformat = 1) then format_date = monthpart & "-" & daypart & "-" & yearpart end if if(dataformat = 2) then format_date = daypart & " " & months(monthpart) & "," & yearpart end if if(dataformat = 3) then format_date = months(monthpart) & " " & daypart & "," & yearpart end if end Function 'Function to format time string Function format_time(date,dataformat) hourpart = Hour(date) minutepart = Minute(date) secondpart = Second(date) format_time = hourpart & ":" & minutepart & ":" & secondpart end Function Function L_HTMLEncode(stringToEncode) if IsNull(stringToEncode) OR IsEmpty(stringToEncode) then L_HTMLEncode = stringToEncode else L_HTMLEncode = Server.HTMLEncode(stringToEncode) end if end Function Function GetPhisicalPath(string_to_transform) pos=InstrRev(LCase(Request.ServerVariables("PATH_TRANSLATED")),LCase(FormAction)) GetPhisicalPath = Left(Request.ServerVariables("PATH_TRANSLATED"), pos-1 )&string_to_transform end Function Function escape_symbols(string_to_escape) if IsNull(string_to_escape) OR IsEmpty(string_to_escape) then string_to_escape_ret = string_to_escape else string_to_escape_ret=Replace(string_to_escape,"'","''") end if escape_symbols=string_to_escape_ret end Function '----------Start Algorithm section------------ %> <%if (bHeaderFired = FALSE) then%>
Advanced Interventional Pain & Sports Medicine Center
Interventional Spine, EMG , Musculoskeletal Ultrasound , Physical Medicine & Rehabilitation
20 Crossroads Dr, Ste 210 Owings Mills, MD 21117 Tel: (410) 581 2969 Fax: (410) 581 5775


If it is an emergency, please call 911 or go the nearest ER. This webpage is not for appointments
or leaving messages. This site reviewed periodically for comments/opinions. You will not receive
any replies. If you have any questions regarding the treatment, please call the office at 410 581 2969.
<%Call PopVars()%> <%if (bHeaderFired = FALSE) then%>
If you have any comments /opinions, feel free to fill in this form. E-mail field is not needed, but you
may want to be available for further communications.
<%Call PopVars()%> <%if(Parameter_1 <> "") Then%> <% '==============Query_1("GuestBook")================ DataSource3 = "Driver={Microsoft Access Driver (*.mdb)}; DBQ= "& DB_Path &"GuestBook.mdb;" PageSize3 = 1 Parameter_1_A=escape_symbols(Parameter_1) Parameter_2_A=escape_symbols(Parameter_2) Parameter_3_A=escape_symbols(Parameter_3) GeneratedSQL= "INSERT INTO [Guests]([Name],[Email],[Comments])"_ &" VALUES ('"&Parameter_1_A&"','"&Parameter_2_A&"','"&Parameter_3_A&"')" %> <%'===============Execute Query And Get Total Count======================== Set Conn3 = Server.CreateObject("ADODB.Connection") Set RS3 = Server.CreateObject("ADODB.RecordSet") RS3.CursorType = adOpenStatic Conn3.Open DataSource3 if Conn3.State = 0 Then Response.Write "Database connection Error: "&DataSource3 Response.End end if RS3.Open GeneratedSQL,Conn3,adOpenKeyset,adLockReadOnly 'both keys are to be variables if Err.Number <> 0 Then Response.Write "Open Recordset Error:
<%=QueryOutput_8%>
<%=QueryOutput_6%>
<%Call PopVars()%> <%Variable_4="indore2003@yahoo.com"%> <%'----------------End Repetition Section------------------------------- RowCount1 = RowCount1 - 1 CurrentRecordNumber1 = CurrentRecordNumber1 + 1 RS1.MoveNext Loop %><% Conn1.Close set rs1 = nothing set Conn1 = nothing %> <%if (bHeaderFired = FALSE) then%>
