% ' FP_ASP ASP Automatically generated by a Frontpage Component. Do not Edit. On Error Resume Next Session("FP_OldCodePage") = Session.CodePage Session("FP_OldLCID") = Session.LCID Session.CodePage = 1252 Err.Clear strErrorUrl = "" If Request.ServerVariables("REQUEST_METHOD") = "POST" Then If Request.Form("VTI-GROUP") = "0" Then Err.Clear Set fp_conn = Server.CreateObject("ADODB.Connection") FP_DumpError strErrorUrl, "Cannot create connection" Set fp_rs = Server.CreateObject("ADODB.Recordset") FP_DumpError strErrorUrl, "Cannot create record set" fp_conn.Open Application("PH 318 Quiz_Pinholes_Shadows2_ConnectionString") FP_DumpError strErrorUrl, "Cannot open database" fp_rs.Open "Results", fp_conn, 1, 3, 2 ' adOpenKeySet, adLockOptimistic, adCmdTable FP_DumpError strErrorUrl, "Cannot open record set" fp_rs.AddNew FP_DumpError strErrorUrl, "Cannot add new record set to the database" Dim arFormFields0(30) Dim arFormDBFields0(30) Dim arFormValues0(30) arFormFields0(0) = "pinhole_camera_fuzzy_image_reasons_11b" arFormDBFields0(0) = "pinhole_camera_fuzzy_image_reasons_11b" arFormValues0(0) = Request("pinhole_camera_fuzzy_image_reasons_11b") arFormFields0(1) = "large_hole_fuzziness_reason_12b1" arFormDBFields0(1) = "large_hole_fuzziness_reason_12b1" arFormValues0(1) = Request("large_hole_fuzziness_reason_12b1") arFormFields0(2) = "large_hole_fuzziness_reason_12b2" arFormDBFields0(2) = "large_hole_fuzziness_reason_12b2" arFormValues0(2) = Request("large_hole_fuzziness_reason_12b2") arFormFields0(3) = "large_hole_fuzziness_reason_12b3" arFormDBFields0(3) = "large_hole_fuzziness_reason_12b3" arFormValues0(3) = Request("large_hole_fuzziness_reason_12b3") arFormFields0(4) = "pinhole_camera_fuzzyimage_reasons_11a" arFormDBFields0(4) = "pinhole_camera_fuzzyimage_reasons_11a" arFormValues0(4) = Request("pinhole_camera_fuzzyimage_reasons_11a") arFormFields0(5) = "shadow_shape_2a" arFormDBFields0(5) = "shadow_shape_2a" arFormValues0(5) = Request("shadow_shape_2a") arFormFields0(6) = "shadow_shape_2b" arFormDBFields0(6) = "shadow_shape_2b" arFormValues0(6) = Request("shadow_shape_2b") arFormFields0(7) = "sunlight_shadows_8a1" arFormDBFields0(7) = "sunlight_shadows_8a1" arFormValues0(7) = Request("sunlight_shadows_8a1") arFormFields0(8) = "diffraction_def" arFormDBFields0(8) = "diffraction_def" arFormValues0(8) = Request("diffraction_def") arFormFields0(9) = "small_hole_fuzziness_reason_12a1" arFormDBFields0(9) = "small_hole_fuzziness_reason_12a1" arFormValues0(9) = Request("small_hole_fuzziness_reason_12a1") arFormFields0(10) = "sunlight_shadows_8a2" arFormDBFields0(10) = "sunlight_shadows_8a2" arFormValues0(10) = Request("sunlight_shadows_8a2") arFormFields0(11) = "small_hole_fuzziness_reason_12a2" arFormDBFields0(11) = "small_hole_fuzziness_reason_12a2" arFormValues0(11) = Request("small_hole_fuzziness_reason_12a2") arFormFields0(12) = "sunlight_shadows_8a3" arFormDBFields0(12) = "sunlight_shadows_8a3" arFormValues0(12) = Request("sunlight_shadows_8a3") arFormFields0(13) = "small_hole_fuzziness_reason_12a3" arFormDBFields0(13) = "small_hole_fuzziness_reason_12a3" arFormValues0(13) = Request("small_hole_fuzziness_reason_12a3") arFormFields0(14) = "sunlight_shadows_8a4" arFormDBFields0(14) = "sunlight_shadows_8a4" arFormValues0(14) = Request("sunlight_shadows_8a4") arFormFields0(15) = "pinhole_camera_image_9a" arFormDBFields0(15) = "pinhole_camera_image_9a" arFormValues0(15) = Request("pinhole_camera_image_9a") arFormFields0(16) = "pinhole_camera_image_9b" arFormDBFields0(16) = "pinhole_camera_image_9b" arFormValues0(16) = Request("pinhole_camera_image_9b") arFormFields0(17) = "umbra_def_4" arFormDBFields0(17) = "umbra_def_4" arFormValues0(17) = Request("umbra_def_4") arFormFields0(18) = "pinhole_camera_image_9c" arFormDBFields0(18) = "pinhole_camera_image_9c" arFormValues0(18) = Request("pinhole_camera_image_9c") arFormFields0(19) = "Name" arFormDBFields0(19) = "Name" arFormValues0(19) = Request("Name") arFormFields0(20) = "shadows_formation_1" arFormDBFields0(20) = "shadows_formation_1" arFormValues0(20) = Request("shadows_formation_1") arFormFields0(21) = "fuzzy_edged_shadows_3a" arFormDBFields0(21) = "fuzzy_edged_shadows_3a" arFormValues0(21) = Request("fuzzy_edged_shadows_3a") arFormFields0(22) = "pinhole_camera_image_9d" arFormDBFields0(22) = "pinhole_camera_image_9d" arFormValues0(22) = Request("pinhole_camera_image_9d") arFormFields0(23) = "fuzzy_edged_shadows_3b" arFormDBFields0(23) = "fuzzy_edged_shadows_3b" arFormValues0(23) = Request("fuzzy_edged_shadows_3b") arFormFields0(24) = "light_source_seen_from_umbra_5" arFormDBFields0(24) = "light_source_seen_from_umbra_5" arFormValues0(24) = Request("light_source_seen_from_umbra_5") arFormFields0(25) = "penumbra_def_6" arFormDBFields0(25) = "penumbra_def_6" arFormValues0(25) = Request("penumbra_def_6") arFormFields0(26) = "light_source_seen_from_penumbra_7a" arFormDBFields0(26) = "light_source_seen_from_penumbra_7a" arFormValues0(26) = Request("light_source_seen_from_penumbra_7a") arFormFields0(27) = "light_source_seen_from_penumbra_7b" arFormDBFields0(27) = "light_source_seen_from_penumbra_7b" arFormValues0(27) = Request("light_source_seen_from_penumbra_7b") arFormFields0(28) = "Did_own_work" arFormDBFields0(28) = "Did_own_work" arFormValues0(28) = Request("Did_own_work") arFormFields0(29) = "light_source_seen_from_penumbra_7c" arFormDBFields0(29) = "light_source_seen_from_penumbra_7c" arFormValues0(29) = Request("light_source_seen_from_penumbra_7c") FP_SaveFormFields fp_rs, arFormFields0, arFormDBFields0 If Request.ServerVariables("REMOTE_HOST") <> "" Then FP_SaveFieldToDB fp_rs, Request.ServerVariables("REMOTE_HOST"), "Remote_computer_name" End If If Request.ServerVariables("HTTP_USER_AGENT") <> "" Then FP_SaveFieldToDB fp_rs, Request.ServerVariables("HTTP_USER_AGENT"), "Browser_type" End If FP_SaveFieldToDB fp_rs, Now, "Timestamp" If Request.ServerVariables("REMOTE_USER") <> "" Then FP_SaveFieldToDB fp_rs, Request.ServerVariables("REMOTE_USER"), "User_name" End If fp_rs.Update FP_DumpError strErrorUrl, "Cannot update the database" fp_rs.Close fp_conn.Close FP_FormConfirmation "text/html; charset=windows-1252",_ "Form Confirmation",_ "Thank you for submitting the following information:",_ "PH%20318%20Quiz_Pinholes_Shadows.asp",_ "Return to the form." End If End If Session.CodePage = Session("FP_OldCodePage") Session.LCID = Session("FP_OldLCID") %>