Created
April 3, 2014 01:14
-
-
Save KZeni/9946602 to your computer and use it in GitHub Desktop.
Swap the jqhfu_enqueue_scripts() function out (found in jquery-html5-file-upload.php) with this new one to get https://wordpress.org/plugins/jquery-html5-file-upload/ working as of version 1.3 of that WordPress plugin.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function jqhfu_enqueue_scripts() { | |
$stylepath=JQHFUPLUGINDIRURL.'css/'; | |
$scriptpath=JQHFUPLUGINDIRURL.'js/'; | |
wp_enqueue_style ( 'jquery-ui-style', '//ajax.googleapis.com/ajax/libs/jqueryui/1.10.1/themes/base/jquery-ui.css' ); | |
wp_enqueue_style ( 'jquery-image-gallery-style', '//blueimp.github.io/Gallery/css/blueimp-gallery.min.css'); | |
wp_enqueue_style ( 'jquery-fileupload-ui-style', $stylepath . 'jquery.fileupload-ui.css'); | |
wp_enqueue_script ( 'enable-html5-script', '//html5shim.googlecode.com/svn/trunk/html5.js'); | |
if(!wp_script_is('jquery')) { | |
wp_enqueue_script ( 'jquery', '//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js',array(),'',false); | |
} | |
wp_enqueue_script ( 'jquery-ui-script', '//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'tmpl-script', '//blueimp.github.io/JavaScript-Templates/js/tmpl.min.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'load-image-script', '//blueimp.github.io/JavaScript-Load-Image/js/load-image.min.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'canvas-to-blob-script', '//blueimp.github.io/JavaScript-Canvas-to-Blob/js/canvas-to-blob.min.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-image-gallery-script', '//blueimp.github.io/jQuery-Image-Gallery/js/jquery.image-gallery.min.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-iframe-transport-script', $scriptpath . 'jquery.iframe-transport.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-fileupload-script', $scriptpath . 'jquery.fileupload.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-fileupload-fp-script', $scriptpath . 'jquery.fileupload-fp.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-fileupload-ui-script', $scriptpath . 'jquery.fileupload-ui.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'jquery-fileupload-jui-script', $scriptpath . 'jquery.fileupload-jui.js',array('jquery'),'',true); | |
wp_enqueue_script ( 'transport-script', $scriptpath . 'cors/jquery.xdr-transport.js',array('jquery'),'',true); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment