Server IP : 103.6.199.200 / Your IP : 3.145.75.238 Web Server : Microsoft-IIS/10.0 System : Windows NT EMPUSA 10.0 build 20348 (Windows Server 2016) i586 User : EMPUSA$ ( 0) PHP Version : 7.4.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : C:/Domains/asiageml/asiagemlab.com/wwwroot/lab/ |
Upload File : |
<%Response.Buffer =true%> <HTML> <HEAD><Link href=..\inc\StandardStyle.css type=text/css rel=stylesheet></HEAD> <title>Certificate Setup</title> <BODY> <%docName="certNew"%> <!--#include file="../inc/checklogin.inc"--> <!--#include file="../inc/connection.inc"--> <!--#include file="../inc/dbOpen.inc"--> <!--#include file="menu.asp" --> <HR><b>Certificate Update</B><HR> <% dataaction = Request.Form ("dataaction") vcertID = Request ("searchID") if dataaction ="Submit" then vGemologist = delQuote(Request.Form ("gemologist")) vItem = delQuote(Request.Form ("item")) vComment = delQuote(Request.Form ("comment")) vWeight = delQuote(Request.Form ("weight")) vColor = delQuote(Request.Form ("color")) vShape = delQuote(Request.Form ("shape")) vClarity = delQuote(Request.Form ("clarity")) vOrigin = delQuote(Request.Form ("origin")) vMeasurement = delQuote(Request.Form ("measurement")) vIP = Request.ServerVariables("REMOTE_ADDR") if vItem<>"" then sql = "Update log set gemologist='" & vGemologist &"', item='" & vItem &"', remarks='" & vComment &"', weight='" & vWeight &"', color='" & vColor &"' "_ & ", shape='" & vShape &"', clarity='" & vClarity &"', origin='" & vOrigin &"', measurement='" & vMeasurement &"' "_ & ", ip='" &vIP &"', dateUpdate='" & dateAdd("h",0,now) &"' where ID=" & vcertID 'Response.Write sql 'Response.End db.execute sql Response.Write "<font color=red>Update Successfully.</font>" else Response.Write "<font color=red>Update NOT Success!</font>" end if end if '****************** START********************** sql = "Select reportNo,gemologist, item,weight,color, shape, clarity, origin, measurement, remarks, dateCreate from log where ID=" & vcertID &"" set rs= server.CreateObject ("ADODB.recordset") rs.Open sql,db,adOpenStatic,adLockReadOnly if not rs.EOF then vReportNo = rs("reportNo") vGemologist = rs("gemologist") vItem = rs("item") vWeight = rs("weight") vColor = rs("color") vShape = rs("shape") vClarity = rs("clarity") vOrigin = rs("origin") vMeasurement = rs("measurement") vComment = rs("remarks") vDateCreate = rs("dateCreate") 'vmode = rs("mode") else Response.Write "Record not found." Response.Write "<input type=button onclick=history.back(); value=Back>" %><!--#include file="../inc/dbClose.inc"--><% Response.End end if rs.Close %> <% '************ Generate QR Code **************** Function SaveBinaryData(FileName, ByteArray) Const adTypeBinary = 1 Const adSaveCreateOverWrite = 2 Dim BinaryStream Set BinaryStream = CreateObject("ADODB.Stream") BinaryStream.Type = adTypeBinary BinaryStream.Open BinaryStream.Write ByteArray BinaryStream.SaveToFile FileName, adSaveCreateOverWrite End Function 'Set objHTTP = Server.CreateObject("Msxml2.ServerXMLHTTP") ' ***Point to an image file with adequate access permissions granted 'objHTTP.open "GET", "https://chart.googleapis.com/chart?chs=150x150&cht=qr&chl=https://www.asiagemlab.com/report.asp?repID=" & vReportNo & "&choe=UTF-8",false 'objHTTP.send '****Response.BinaryWrite objHTTP.ResponseBody QRName = "QR_" & replace(vReportNo,"/","-") & ".png" 'call SaveBinaryData(Server.MapPath("../imagesQRcode/") & "\" & QRName, objHTTP.ResponseBody) 'Set objHTTP = Nothing %> <form action=certUpdate.asp name=f method=post onSubmit="return checkRequiredField(this)"> <TABLE cellSpacing=0 cellPadding=0 width="90%" border=0> <TR><TD colspan=4>*<font color=RED size=2>Required Fields</font></TD></TR> <TR><TD colspan=4><img src="../imagesQRcode/QR_<%=replace(vReportNo,"/","-")%>.png"> <% dim filesys Set filesys = CreateObject("Scripting.FileSystemObject") vMemoStoneFile = Server.MapPath ("../upload/imagesCert/" & replace(vReportNo,"/","-") &".jpg") If filesys.FileExists(vMemoStoneFile) Then 'Response.Write("File location: " & vQRCodeFile) Response.write "<img src='../upload/imagesCert/" & replace(vReportNo,"/","-") &".jpg' width=250>" else Response.write "<img src='../upload/imagesCert/NA.jpg'>" End If %> </TD></TR> <TR><TD width=10%>  Report No</TD><TD>:</TD><TD><%=left(vReportNo,10)%></TD></TR> <TR><TD>  Date</TD><TD>:</TD><TD><%=formatdatetime(vDateCreate,1)%></TD></TR> <TR> <TD>* Gemologist</TD><TD>:</TD><TD> <select name=gemologist> <option value=''>-</option> <% '***Display ****' Response.Write "<option value='" & vGemologist &"' selected >" & vGemologist &"</option>" sql = "select usage1 from sysDetail where base='gemologist' and enabled='Y' order by usage1 asc" rs.Open sql,db,adOpenStatic,adLockReadOnly if not rs.EOF then do while not rs.EOF Response.Write "<option value='" & rs("usage1") &"' " if vGemologist = rs("usage1") then Response.Write " selected " Response.Write ">" & rs("usage1") &"</option>" rs.MoveNext loop end if rs.Close %></select> </TD></TR> <TR><TD>* Identity</TD><TD>:</TD><TD><input name=item value="<%=vItem%>" size=60></TD></TR> <TR><TD>  Color</TD><TD>:</TD><TD><input name=color value="<%=vColor%>" size=50></TD></TR> <TR><TD>  Shape & Cut</TD><TD>:</TD><TD><input name=shape value="<%=vShape%>" size=50></TD></TR> <TR><TD>  Weight</TD><TD>:</TD><TD><input name=weight value="<%=vWeight%>"></TD></TR> <TR><TD>  Measurement</TD><TD>:</TD><TD><input name=measurement value="<%=vMeasurement%>" size=50></TD></TR> <TR><TD>  Clarity</TD><TD>:</TD><TD><input name=clarity value="<%=vClarity%>"></TD></TR> <TR><TD>  Origin</TD><TD>:</TD><TD><input name=origin value="<%=vOrigin%>" size=50></TD></TR> <TR><TD valign=top>  Comments</TD><TD valign=top>:</TD> <TD><textarea name=comment cols=50 rows=2><%=vComment%></textarea></TD></TR> <TR><TD colspan=4 align=middle><input type=submit value="Submit" name=dataAction></TD></TR> <input type=hidden name=searchID value="<%=vcertID%>"> </TABLE> </form> <!--#include file="../inc/dbClose.inc"--> <SCRIPT language=javascript> <!-- function checkRequiredField(){ if (f.item.value==""){ alert("Please enter your Identity here!"); f.item.focus(); return false; } return true; } --> </SCRIPT> </body> </HTML>