[Extra Feature] Loading bar with shortcode & Jquery
-
Thanks for the great plugin.
Thought I would add my addition.
On the shortcode version of the plugin, I have added a loading bar by adding the following code into the main rad-dropbox-uploader.php file.
Firstly give the form the ID upload-file (id=”upload-file”)
On the line above the form add the following image code: (just under the string return message. (roughly line 123)
I have linked the image to one in my theme directory using https://www.ajaxload.info/ to make a loading gif.
<img src="'.get_template_directory_uri().'/images/loadingbar.gif" style="display: none;" id="loading_image">
In the head of your website add the following jquery:
<script> $(document).ready(function() { $('#upload-file').submit(function() { $('#loading_image').show(); // show animation return true; // allow regular form submission }); }); </script>
https://www.ads-software.com/extend/plugins/rad-dropbox-uploader/
- The topic ‘[Extra Feature] Loading bar with shortcode & Jquery’ is closed to new replies.