Hi,
From reading other posts it appears I have a bootstrap Jquery issue preventing image uploads. Everything works perfectly with WordPress 2013 theme, so a theme issue rather than a plugin issue.
I’ve attached the script loading from functions.php, any help in getting bootstrap.js loaded before the wp jquery ui (as you explained in another post) would be gratefully received.
I’m on the latest version of everything and running a child theme setup.
Thx in advance
/* LOAD STYLES & SCRIPTS
================================================== */
function sf_enqueue_styles() {
$options = get_option(‘sf_flexform_options’);
$enable_responsive = $options[‘enable_responsive’];
wp_register_style(‘bootstrap’, SF_LOCAL_PATH . ‘/css/bootstrap.min.css’, array(), NULL, ‘screen’);
wp_register_style(‘bootstrap-responsive’, SF_LOCAL_PATH . ‘/css/bootstrap-responsive.min.css’, array(), NULL, ‘screen’);
wp_register_style(‘fontawesome-css’, SF_LOCAL_PATH . ‘/css/font-awesome.min.css’, array(), NULL, ‘screen’);
wp_register_style(‘main-css’, get_stylesheet_directory_uri() . ‘/style.css’, array(), NULL, ‘screen’);
wp_register_style(‘responsive-css’, SF_LOCAL_PATH . ‘/css/responsive.css’, array(), NULL, ‘screen’);
wp_enqueue_style(‘bootstrap’);
wp_enqueue_style(‘bootstrap-responsive’);
wp_enqueue_style(‘fontawesome-css’);
wp_enqueue_style(‘main-css’);
if ($enable_responsive) {
wp_enqueue_style(‘responsive-css’);
}
}
add_action(‘wp_enqueue_scripts’, ‘sf_enqueue_styles’);
function sf_enqueue_scripts() {
wp_register_script(‘sf-bootstrap-js’, get_template_directory_uri() . ‘/js/bootstrap.min.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-flexslider’, get_template_directory_uri() . ‘/js/jquery.flexslider-min.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-isotope’, get_template_directory_uri() . ‘/js/jquery.isotope.min.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-hoverIntent’, get_template_directory_uri() . ‘/js/jquery.hoverIntent.min.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-easing’, get_template_directory_uri() . ‘/js/jquery.easing.1.3.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-carouFredSel’, get_template_directory_uri() . ‘/js/jquery.carouFredSel-6.2.0-packed.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-prettyPhoto’, get_template_directory_uri() . ‘/js/jquery.prettyPhoto.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-viewjs’, get_template_directory_uri() . ‘/js/view.min.js?auto’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-fitvids’, get_template_directory_uri() . ‘/js/jquery.fitvids.js’, ‘jquery’, NULL , TRUE);
wp_register_script(‘sf-maps’, ‘http://maps.google.com/maps/api/js?sensor=false’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-respond’, get_template_directory_uri() . ‘/js/respond.min.js’, ‘jquery’, NULL, TRUE);
wp_register_script(‘sf-twitter-widgets’, ‘//platform.twitter.com/widgets.js’, NULL, NULL, TRUE);
wp_register_script(‘sf-functions’, get_template_directory_uri() . ‘/js/functions.js’, ‘jquery’, NULL, TRUE);
wp_enqueue_script(‘jquery’);
wp_enqueue_script(‘sf-bootstrap-js’);
wp_enqueue_script(‘sf-hoverIntent’);
wp_enqueue_script(‘sf-easing’);
wp_enqueue_script(‘sf-flexslider’);
wp_enqueue_script(‘sf-prettyPhoto’);
wp_enqueue_script(‘sf-fitvids’);
wp_enqueue_script(‘sf-respond’);
if ( in_array( ‘woocommerce/woocommerce.php’, apply_filters( ‘active_plugins’, get_option( ‘active_plugins’ ) ) ) ) {
if (!is_account_page()) {
wp_enqueue_script(‘sf-viewjs’);
}
} else {
wp_enqueue_script(‘sf-viewjs’);
}
if (!is_admin()) {
wp_enqueue_script(‘sf-functions’);
}
if (is_singular()) {
wp_enqueue_script(‘comment-reply’);
}
}
add_action(‘wp_enqueue_scripts’, ‘sf_enqueue_scripts’);
function sf_admin_scripts() {
wp_register_script(‘admin-functions’, get_template_directory_uri() . ‘/js/sf-admin.js’, ‘jquery’, ‘1.0’, TRUE);
wp_enqueue_script(‘admin-functions’);
}
add_action(‘admin_init’, ‘sf_admin_scripts’);
function sf_load_custom_script() {
global $include_maps, $include_isotope, $include_carousel;
if ($include_maps) {
wp_print_scripts(‘sf-maps’);
}
if ($include_isotope) {
wp_print_scripts(‘sf-isotope’);
}
if ($include_carousel) {
wp_print_scripts(‘sf-carouFredSel’);
}
$options = get_option(‘sf_flexform_options’);
}
add_action(‘wp_footer’, ‘sf_load_custom_script’);