Im trying to upload pictures using form in ASP classic. Found this piece of code that uses two asp class files written - clsUpload.asp
and clsFields.asp
.
The upload file looks something like this:
Dim objUpload
Dim strFile, strPath
' Instantiate Upload Class '
Set objUpload = New clsUpload
strFile = objUpload.Fields("file").FileName
strPath = server.mappath("/data") & "/" & strFile
' Save the binary data to the file system '
objUpload("file").SaveAs strPath
Set objUpload = Nothing
But I think the code is trying to save the picture into database using a binary data field. Want I want is to save the picture into the folder and save the filename to a database field.
Any idea how to do it?