Hi,
I have an uploader on a page with other data.
Uploading items is optional. But if no items are selected my page won't postback (and the rest of the data cannot be saved).
Where do I set that uploading of images is optional in the ajaxuploader?
this is my code:
- <script type="text/javascript">
-
- function submitbutton_click() {
- var submitbutton = document.getElementById('<%=btnSave.ClientID %>');
- var uploadimg = document.getElementById('<%=uplImages.ClientID %>');
- var uploadobj = document.getElementById('<%=uplAttach.ClientID %>');
- if (!window.filesuploaded) {
- if (uploadobj.getqueuecount() > 0) {
- uploadobj.startupload();
- }
- if (uploadimg.getqueuecount() > 0) {
- uploadimg.startupload();
- }
- return false;
- }
- window.filesuploaded = false;
- return true;
- }
-
- function CuteWebUI_AjaxUploader_OnPostback() {
- window.filesuploaded = true;
- var submitbutton = document.getElementById('<%=btnSave.ClientID %>');
- submitbutton.click();
- return false;
- }
- </script>
Any help would be appreciated
thx