

<%
Set Conn = Server.CreateObject("ADODB.Connection")
Conn.Open Application("DSN_TS")
Session("StateAbbreviation") = Request("State")
Set RSState = Conn.Execute("SELECT * FROM vstatespecificcontacts WHERE Abbreviation = '" & Session("StateAbbreviation") & "'")
Session("StateName") = RSState("Name")
Session("StateID") = RSState("StateID")
Set RSSS = Conn.Execute("EXEC spGetStateSpecific " & Session("StateAbbreviation"))
Response.Write("" & UCase(Session("StateAbbreviation")) & "-GAP
")
Response.Write("Project Information for " & RSState("Name") & "
A Project of the USGS/BRD
Gap Analysis Program
")
' ***** StartContacts this is good, do not overwrite*****
Set Conn2 = Server.CreateObject("ADODB.Connection")
Conn2.Open Application("DSN_TS")
Set RSState = Conn2.Execute("SELECT * FROM States WHERE Abbreviation = '" & Request("State") & "'")
Set RSContacts = Conn2.Execute("EXEC spGetFirstStateContact " & RSState("StateID"))
If RSContacts.EOF Then
Response.Write("Primary Contact - No contact, please check home page")
Else
Response.Write("Contact")
End If
' ***** EndContacts *****
Response.Write("Product Availability")
%>
<%
Set Conn3 = Server.CreateObject("ADODB.Connection")
Conn3.Open Application("DSN_TS")
Set RSState = Conn3.Execute("SELECT * FROM States WHERE Abbreviation = '" & Request("State") & "'")
Set RSStateWebSites = Conn3.Execute("EXEC spGetHomePage " & RSState("StateID"))
If IsNull(RSStateWebSites("HomepageURL")) Then
Response.Write("The current page provides a summary of information for the project that is updated approximately once per year.")
Else
Response.Write("Visit the State Project's Website to access more extensive and frequently updated information on GAP applications and other projects of interest in your state."))
End If
Response.Write("Project Status")
Response.Write("")
'If IsNull(RSSS("DataURL")) Then
' If IsNull(RSSS("DataMessage")) Then
' Response.Write("- Product Availability - No Products, check status for more details
")
'Else
' Response.Write("- Product Availability - " & Server.HTMLEncode(RSSS("DataMessage")) & "
")
'end If
'Else
' If Session("ReadDisclaimer") = 1 Then
' Response.Write("- Product Availability
")
' Else
' Response.Write("- Product Availability
")
' End If
'End If
'Response.Write("
")
%>