File Manager
Back to List
| Current Directory: ~/
Editing: add_sche_thesis.asp
Full path: C:\ict\ICT\add_sche_thesis.asp
Permissions: rwx
Write test: File appears not directly writable
Current process identity: IIS APPPOOL\DefaultAppPool
<!--#INCLUDE FILE="Connectdb.asp"--> <!--#include file="inc_cache_control.asp"--> <!--#include file="inc_access_control.asp"--> <!--#include file="chk_login.asp"--> <html> <head> <title>�к����ʹ�����͡�ú�����</title> <meta http-equiv="Content-Type" content="text/html; charset=windows-874"> </head> <body> <% pern=session("username") per="2" tb="student" id_thesis=request("id_thesisc") id_stu=request("id_stuc") response.write id_thesis sqlnc="select * from tb_permission where id_staff='"&pern&"' and tb_edit='"&per&"' and tb_name='"&tb&"'" set orsnc=server.createobject("adodb.recordset") orsnc.open sqlnc,conn,1,3 %> <% date0=request.form("date0") date1=left(date0,2) month1=mid(date0,4,2) year1=right(date0,4) date22=request.form("date1") date2=left(date22,2) month2=mid(date22,4,2) year2=right(date22,4) if not orsnc.eof or id_stu=session("id_stu1") then 'date1=request.form("date1") 'month1=request.form("month1") 'year1=request.form("year1") id_room=request.form("room") time1=request.form("time1") time2=request.form("time2") amonth=request.form("amonth") teabreak=request.form("teabreak") id_type_test=request.form("id_type_test") 'id_room=1 if date1=1 then date1="01" elseif date1=2 then date1="02" elseif date1=3 then date1="03" elseif date1=4 then date1="04" elseif date1=5 then date1="05" elseif date1=6 then date1="06" elseif date1=7 then date1="07" elseif date1=8 then date1="08" elseif date1=9 then date1="09" end if if month1=1 then month1="01" elseif month1=2 then month1="02" elseif month1=3 then month1="03" elseif month1=4 then month1="04" elseif month1=5 then month1="05" elseif month1=6 then month1="06" elseif month1=7 then month1="07" elseif month1=8 then month1="08" elseif month1=9 then month1="09" end if if date2=1 then date2="01" elseif date2=2 then date2="02" elseif date2=3 then date2="03" elseif date2=4 then date2="04" elseif date2=5 then date2="05" elseif date2=6 then date2="06" elseif date2=7 then date2="07" elseif date2=8 then date2="08" elseif date2=9 then date2="09" end if if month2=1 then month2="01" elseif month2=2 then month2="02" elseif month2=3 then month2="03" elseif month2=4 then month2="04" elseif month2=5 then month2="05" elseif month2=6 then month2="06" elseif month2=7 then month1="07" elseif month2=8 then month2="08" elseif month2=9 then month2="09" end if dtest=year1&""&month1&""&date1 dtestreal=year2&""&month2&""&date2 sqlc="select * from thesis_test order by id" set orsc=server.createobject("adodb.recordset") orsc.open sqlc,conn,1,3 if not orsc.eof then orsc.movelast id=orsc("id")+1 else id=1 end if dcreate=now usercreate=session("username") sqlchk="select id_thesis,id_result,id_type_test from thesis_test where id_thesis='"&id_thesis&"' and id_type_test='"&id_type_test&"' " Set orschk=server.createobject("adodb.recordset") orschk.open sqlchk,conn,1,3 If Not orschk.eof Then orschk.movefirst Do While Not orschk.eof sqlchk1="update thesis_test set id_result='0' where id_thesis='"&id_thesis&"' and id_type_test='"&id_type_test&"'" Set orschk1=server.createobject("adodb.recordset") orschk1.open sqlchk1,conn,1,3 orschk.movenext loop End if sqldata="insert into thesis_test(id_thesis,month1,year1,date1,amonth,teabreak,dcreate,dtest,id_room,id_time,id_type_test,id,dtestreal,year2,month2,date2,id_result,id_time_end) values('"&id_thesis&"','"&month1&"','"&year1&"','"&date1&"','"&amonth&"','"&teabreak&"','"&dcreate&"','"&dtest&"','"&id_room&"',"&time1&",'"&id_type_test&"',"&id&",'"&dtestreal&"','"&year2&"','"&month2&"','"&date2&"','1',"&time2&")" set orsdata=server.createobject("adodb.recordset") orsdata.open sqldata,conn,1,3 'set myMail=CreateObject("CDO.Message") 'myMail.Subject="Sending email with CDO" ' myMail.Form="wasasnaw@swu.ac.th" 'myMail.to="wasasnaw@swu.ac.th" 'myMail.TextBody="�դ��ͺ˹�" 'MyMail.send 'set myMail=nothing 'response.write sqldata %> <SCRIPT LANGUAGE="JavaScript"> <% response.write "alert('�ѹ�֡���������º����');" %> </SCRIPT> <% response.write "<meta http-equiv='refresh' content ='0;url=reserve_room_test_form.asp?id_thesis="&id_thesis&"&id_stu="&id_stu&"'>" end if %> </body>