this is what i have so far i aint even checked it but its asp, i think i should work in cf if i change it to cfif and cf efelseif, sorry im new to this and im still learning
the two user names = joe1 and joe2 these are hard coded in the page but could come from a db
if from a db the table = users
and datasource = log
<%
'do i need to declare variables here
'Build connection with database
set conn = server.CreateObject ("ADODB.Connection")
conn.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & server.MapPath ("\db\downtime.mdb")
set rs = server.CreateObject ("ADODB.Recordset")
'Open record with todays date
rs.Open "SELECT * FROM productioninfo where txtdate='"now()"'", conn, 1
'If there is no record with the date do entry form
rs.close
conn.close
set rs=nothing
set conn=nothing
Response.Redirect("productioninfo_entryform.cfm")
elseif
'check for supervisors name
if rs("production_supervisors_name") = "joe1" and rs("production_supervisors_name") = "joe2" then
'if either name is missing do form
rs.Close
conn.Close
set rs=nothing
set conn=nothing
Response.Redirect("productioninfo_entryform.cfm")
else
'if all above ifs are true do main page according to userlevel
rs.Close
conn.Close
set rs=nothing
set conn=nothing
Response.Redirect("default.asp")
end if
%>