G
Gary \(Girish\)
Hello:
I am using SA-FileUp to enable members to upload their product
images
to my ISP sever. When member uploaded a new image file, the file name is
replaced with the member ID and the old file is then overwrited.
Here is the problem:
Member can uploaded new image at "Upload page" BEFORE viewing the new
image at the "Detail page" without any problem. However, when member 1st
viewed the image at the "Detail page" and then upload the new image at the
"Upload page", the whole page is blocked more than 1 minute and the browser
will only load the old image unless manually he/she has to manually reload
(netscape) or refresh (IE) the browser.
It should not be the bandwidth problem because I can upload diff image
(with any size) as long as I don't load the old image from the browser
BEFORE
upload the new image to the server. I think the problem is caused by
caching.
I already put expires=0 on both "Display" and "Upload" page but the problem
still exist.
<% Response.Expires=0 %>
<html>
<head>
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
</head>
vin=request("vin")
'response.write(vin)
Set upl = Server.CreateObject("SoftArtisans.FileUp")
upl.SaveAs "i:\pp\temp\" + session("rand_id") + ".jpg"
Set objImageGen = Server.CreateObject("softartisans.ImageGen")
response.write("i:\pp\temp\" + session("rand_id") + ".jpg")
objImageGen.LoadImage "I:\pp\temp\" + session("rand_id") + ".jpg"
' Check width of image
img_width=objImageGen.Width
if (img_width>500) then
objImageGen.CreateThumbnail 500,0,2
end if
'Save main image to i:/pp/carmart/photos
objImageGen.SaveImage 0, 3, "i:\pp\carmart\photos\" + vin + "-1.jpg"
'Save thumbnail to i:/pp/carmart/thumbs
objImageGen.CreateThumbnail 101,0,2
objImageGen.SaveImage 0, 3, "i:\pp\carmart\thumbs\" + vin + "-1t.jpg"
session("rand_id")=""
I am using SA-FileUp to enable members to upload their product
images
to my ISP sever. When member uploaded a new image file, the file name is
replaced with the member ID and the old file is then overwrited.
Here is the problem:
Member can uploaded new image at "Upload page" BEFORE viewing the new
image at the "Detail page" without any problem. However, when member 1st
viewed the image at the "Detail page" and then upload the new image at the
"Upload page", the whole page is blocked more than 1 minute and the browser
will only load the old image unless manually he/she has to manually reload
(netscape) or refresh (IE) the browser.
It should not be the bandwidth problem because I can upload diff image
(with any size) as long as I don't load the old image from the browser
BEFORE
upload the new image to the server. I think the problem is caused by
caching.
I already put expires=0 on both "Display" and "Upload" page but the problem
still exist.
<% Response.Expires=0 %>
<html>
<head>
<META HTTP-EQUIV="PRAGMA" CONTENT="NO-CACHE">
</head>
vin=request("vin")
'response.write(vin)
Set upl = Server.CreateObject("SoftArtisans.FileUp")
upl.SaveAs "i:\pp\temp\" + session("rand_id") + ".jpg"
Set objImageGen = Server.CreateObject("softartisans.ImageGen")
response.write("i:\pp\temp\" + session("rand_id") + ".jpg")
objImageGen.LoadImage "I:\pp\temp\" + session("rand_id") + ".jpg"
' Check width of image
img_width=objImageGen.Width
if (img_width>500) then
objImageGen.CreateThumbnail 500,0,2
end if
'Save main image to i:/pp/carmart/photos
objImageGen.SaveImage 0, 3, "i:\pp\carmart\photos\" + vin + "-1.jpg"
'Save thumbnail to i:/pp/carmart/thumbs
objImageGen.CreateThumbnail 101,0,2
objImageGen.SaveImage 0, 3, "i:\pp\carmart\thumbs\" + vin + "-1t.jpg"
session("rand_id")=""