From 4f57a2a6e8c9f1130b4772125aa6d434e6c2a5c3 Mon Sep 17 00:00:00 2001 From: Cash Costello Date: Sat, 30 Oct 2010 15:17:53 +0000 Subject: turning off choose and upload after the images are uploaded --- views/default/tidypics/forms/ajax_upload.php | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'views/default/tidypics/forms/ajax_upload.php') diff --git a/views/default/tidypics/forms/ajax_upload.php b/views/default/tidypics/forms/ajax_upload.php index 912d1c03e..1d2a240ad 100644 --- a/views/default/tidypics/forms/ajax_upload.php +++ b/views/default/tidypics/forms/ajax_upload.php @@ -102,6 +102,11 @@ $("#uploadify").uploadify({ $("#tidypics_upload_button").removeClass('tidypics_disable'); }, 'onAllComplete' : function() { + $("#tidypics_choose_button").addClass('tidypics_disable'); + $("#tidypics_upload_button").addClass('tidypics_disable'); + $("#tidypics_choose_button").attr("href", "javascript:void(0)"); + $("#tidypics_upload_button").attr("href", "javascript:void(0)"); + $("#tidypics_describe_button").removeClass('tidypics_disable'); $.post( '', @@ -112,6 +117,11 @@ $("#uploadify").uploadify({ } ); }, + 'onComplete' : function(event, queueID) { + // check for errors here + $("#uploadify" + queueID + " > .cancel").remove(); + return false; + }, 'onCancel' : function(event, queueID, fileObj, data) { if (data.fileCount == 0) { $("#tidypics_upload_button").addClass('tidypics_disable'); -- cgit v1.2.3