[Mapbender-commits] r5596 - trunk/mapbender/http/plugins
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Tue Feb 23 04:11:35 EST 2010
Author: kmq
Date: 2010-02-23 04:11:31 -0500 (Tue, 23 Feb 2010)
New Revision: 5596
Modified:
trunk/mapbender/http/plugins/jq_upload.js
Log:
added options to disable showing the 'submit' button in case it needs to be done by a script (say , in a jquery.ui.dialog)
Modified: trunk/mapbender/http/plugins/jq_upload.js
===================================================================
--- trunk/mapbender/http/plugins/jq_upload.js 2010-02-23 07:36:52 UTC (rev 5595)
+++ trunk/mapbender/http/plugins/jq_upload.js 2010-02-23 09:11:31 UTC (rev 5596)
@@ -7,6 +7,8 @@
var time = 0;
var timeout = options.timeout || 7000;
var timeinterval = options.interval || 200;
+ // we want the default to be true, and we want the user to be able to write {displaySubmit: false}
+ var displaySubmit = options.displaySubmit? true : false;
var startUpload = function () {
var t = setInterval(function () {
@@ -63,11 +65,13 @@
$form.append($(
"<p id=" + id + "'_form' align='center'><br/>" +
"<input name='myfile' type='file' size='30' />" +
- "<input type='submit' value='Upload' />" +
+
+ (displaySubmit ? "<input type='submit' value='Upload' />": "") +
+
"</p>" +
"<iframe name='" + id + "_target' src='#' " +
"style='width:0;height:0;border:0px solid #fff;'></iframe>"
));
$this.append($form);
});
-};
\ No newline at end of file
+};
More information about the Mapbender_commits
mailing list