Topbar
Topbar
Sign in
|
Join
|
Client Center
Home
Products
Client Center
Contact
Purchase
Support forums
»
Products
»
Ajax Uploader
»
Re: handleselect javascript method
handleselect javascript method
Last post 11-02-2009, 9:03 AM by
cutechat
. 1 replies.
Sort Posts:
Oldest to newest
Newest to oldest
Previous
Next
10-29-2009, 2:49 PM
56796
scott.bradley
Joined on 06-16-2009
Posts 2
handleselect javascript method
Reply
Quote
I am having trouble using your javascript API. I am trying to check if a file already exists in our system, as a user is attempting to upload a file. If it does exist, I need to give them a message asking if they want to overwrite the file. I am trying to use the handleselect method to grab the files that are being uploaded, but i can't seem to get the list of files being uploaded. Here's the code I'm using:
uploader.handleselect =
function
() {
alert(
'handleselect'
);
var
items =
this
.getitems();
alert(
'Files selected: '
+ items.length);
return
false
;
};
If I use the
CuteWebUI_AjaxUploader_OnSelect method, I can get to the files from the "files" parameter, but i think i need to use the handleselect method since i am trying to filter the list of files, then start the upload manually using startupload( ), which by the way doesn't seem to fire when i call it from another javascript method.
Any ideas on how i can get to that list of files from handleselect, and also call startupload? Is there an on-line reference of the javascript methods available on the Uploader object, one that's more complete than
http://ajaxuploader.com/document/index.htm#page=JavaScript-API.htm
?
Thanks...
11-02-2009, 9:03 AM
56841
in reply to
56796
cutechat
Joined on 07-22-2004
Posts 2,332
Re: handleselect javascript method
Reply
Quote
Hi,
In the handleselect event , you can use the same parameters:
uplaoder.handleselect=function(selectingitems)
{
}
You should not use getitems() , because the selectingitems are not added into the uploader items yet.
Regards,
Terry