Appendchunk
Formsize = Request.totalbytes
'The size of the client to get the client formdata = request.binaryRead (Formsize)
'Transfer of data from customers into binary BNCRLF = Chrb (13) & chrb (10) Divider = Leftb (FormData, ClNG (INSTRB (FormData, Bncrlf)) - 1) Datastart = INSTRB (Formdata, Bncrlf & BnCrlf) 4DATAEND = INSTRB (DataStart 1, Formdata, Divider) -DataStartMyData = MIDB (Formdata, DataStart, DataEND)
'The top of the top is the binary data obtained.
SQL = "SELECT * FROM PIC ORDER BY ID DESC" SET RS = Server.createObject ("AdoDb.Recordset") RS.Open SQL, CONN, 3, 2RS.ADDNEWRS ("BIG"). Appendchunk MyData
'Add to the database rs.Update
Rs.close
Getchunk
SET REC = Server.createObject ("AdoDb.Recordset")
strsql = "SELECT IMG FROMAGES where ID =" & Trim (Request ("ID")))
Rec.open strsql, conngraph, 1, 1
Response.contentType = "image / *"
Response.binaryWrite
Rec ("img"). getchunk (7500000)
Rec.close