コード例 #1
0
 function eli_wptheme_scripts()
 {
     global $drjoseph_options;
     /* Fonts */
     $fonts = array('Open Sans' => '400,300,400italic,600,700,800:latin', 'Roboto Condensed' => '400,300,400italic,700:latin');
     wp_enqueue_style('theme-fonts', theme_font_url($fonts), array(), null);
     wp_enqueue_style('font-awesome', ELUSICVE_THEME_ASSETS . 'css/font-awesome.min.css');
     /* Style */
     wp_enqueue_style('bootstrap', ELUSICVE_THEME_ASSETS . 'css/bootstrap.min.css');
     wp_enqueue_style('mmenu-css', ELUSICVE_THEME_ASSETS . 'css/jquery.mmenu.all.min.css');
     wp_enqueue_style('owl-css', ELUSICVE_THEME_ASSETS . 'css/owl.carousel.css');
     wp_enqueue_style('eli-css', ELUSICVE_THEME_ASSETS . 'css/main.css', array('bootstrap'));
     /* Javascripts */
     wp_enqueue_script('bootstrap', ELUSICVE_THEME_ASSETS . 'js/vendor/bootstrap.min.js', array('jquery'), 3.0, TRUE);
     wp_enqueue_script('mmenu', ELUSICVE_THEME_ASSETS . 'js/vendor/jquery.mmenu.min.all.js', array('jquery'), 3.0, TRUE);
     wp_enqueue_script('owl', ELUSICVE_THEME_ASSETS . 'js/vendor/owl.carousel.min.js', array('jquery'), 3.0, TRUE);
     wp_enqueue_script('easing', ELUSICVE_THEME_ASSETS . 'js/vendor/jquery.easing.1.3.js', array('jquery'), 3.0, TRUE);
     wp_enqueue_script('imagesloaded', ELUSICVE_THEME_ASSETS . 'js/vendor/imagesloaded.pkgd.min.js', array('jquery'), 3.0, TRUE);
     if (is_page_template('tpl-frotpage2.php')) {
         wp_enqueue_style('camera-css', ELUSICVE_THEME_ASSETS . 'css/camera.css');
         wp_enqueue_script('mobile.customized', ELUSICVE_THEME_ASSETS . 'js/vendor/jquery.mobile.customized.min.js', array('jquery'), 3.0, TRUE);
         wp_enqueue_script('camera', ELUSICVE_THEME_ASSETS . 'js/vendor/camera.min.js', array('jquery'), 3.0, TRUE);
     }
     wp_enqueue_script('eli-js', ELUSICVE_THEME_ASSETS . 'js/eli-theme.js', array('jquery'), 1.0, TRUE);
     global $eli_options;
     wp_localize_script('eli-js', 'eli_obj', array('site_url' => get_site_url(), 'ajaxUrl' => admin_url('ajax.php'), 'mm_theme' => $eli_options['mobile_menu_theme'], 'mm_show_logo' => $eli_options['show_logo_sx'] ? TRUE : FALSE, 'mm_logo' => $eli_options['logo_url_sx']['url'], 'mm_close' => MCLINIC_THEME_URL . '/images/mm-close.png'));
 }
コード例 #2
0
 function illusive_wptheme_scripts()
 {
     global $illusive_redux;
     $fonts = array('Roboto' => '400,100,300,700,400italic,900');
     wp_enqueue_style('theme-fonts', theme_font_url($fonts), array(), null);
     //Icon front
     wp_enqueue_style('font-awesome', ILLUSIVE_THEME_ASSETS_URI . '/font-awesome/css/font-awesome.min.css', array(), '4.3.0');
     //Illusive front
     wp_enqueue_style('illusive-icon', ILLUSIVE_THEME_ASSETS_URI . '/css/illusive-icon.css', array(), '4.3.0');
     //Bootstrap Customized
     wp_enqueue_style('bootstarp', ILLUSIVE_THEME_ASSETS_URI . '/css/bootstrap.css', array(), '3.3.5');
     wp_enqueue_script('bootstarp-js', ILLUSIVE_THEME_ASSETS_URI . '/js/bootstrap.min.js', array('jquery'), '3.3.5', FALSE);
     //Owl Carousel
     wp_enqueue_style('owl-carousel-css', ILLUSIVE_THEME_ASSETS_URI . '/css/owl.carousel.css', array(), '3.3.5');
     wp_enqueue_script('owl-carousel-js', ILLUSIVE_THEME_ASSETS_URI . '/js/owl.carousel.js', array('jquery'), '3.3.5', FALSE);
     wp_enqueue_script('imagesloaded-js', ILLUSIVE_THEME_ASSETS_URI . '/js/imagesloaded.pkgd.min.js');
     wp_enqueue_script('social-share', get_template_directory_uri() . '/widgets/scripts/buttons.js');
     wp_enqueue_script('scrollTo', ILLUSIVE_THEME_ASSETS_URI . '/js/jquery.scrollTo-1.4.2-min.js', array('jquery'));
     wp_enqueue_script('localscroll', ILLUSIVE_THEME_ASSETS_URI . '/js/jquery.localscroll-1.2.7-min.js', array('jquery'));
     wp_enqueue_script('parallax', ILLUSIVE_THEME_ASSETS_URI . '/js/jquery.parallax-1.1.3.js', array('jquery'), 1.1, false);
     wp_enqueue_style('parallax-css', ILLUSIVE_THEME_ASSETS_URI . '/css/parallax-style.css');
     //Page Loader
     //wp_enqueue_style('pageloader-css', ILLUSIVE_THEME_ASSETS_URI . '/page-loader/css/introLoader.css', array(), '1.6.2');
     //wp_enqueue_script('pageloader-js', ILLUSIVE_THEME_ASSETS_URI . '/page-loader/jquery.introLoader.pack.min.js', array('jquery'), '1.6.2', FALSE);
     //Mobile MEnu
     // wp_enqueue_style('mmenu-style', ILLUSIVE_THEME_ASSETS_URI . '/css/jquery.mmenu.all.css', array(), '5.3.0');
     // wp_enqueue_script('mmenu-js', ILLUSIVE_THEME_ASSETS_URI . '/js/jquery.mmenu.min.all.js', array('jquery'), '5.3.0', FALSE);
     //Slider script
     $slider_type = $illusive_redux['home_slider'];
     if ($slider_type == 'theme-camera') {
         wp_enqueue_style('camera-slider-css', ILLUSIVE_THEME_ASSETS_URI . '/camera/css/camera.css', array(), ILLUSIVE_THEME_VAR);
         wp_enqueue_script('easing', ILLUSIVE_THEME_ASSETS_URI . '/camera/scripts/jquery.easing.1.3.js', array('jquery'), '1.3', FALSE);
         if (wp_is_mobile()) {
             wp_enqueue_script('jquery-mobile', ILLUSIVE_THEME_ASSETS_URI . '/camera/scripts/jquery.mobile.customized.min.js', array('jquery'), '1.3', FALSE);
         }
         wp_enqueue_script('camera-scripts', ILLUSIVE_THEME_ASSETS_URI . '/camera/scripts/camera.min.js', array('jquery'), ILLUSIVE_THEME_VAR, FALSE);
     }
     //jquery magnific popup
     //wp_enqueue_style('magnific-popup', ILLUSIVE_THEME_ASSETS_URI . '/css/magnific-popup.css', array(), '1.0.0');
     //wp_enqueue_script('jquery.magnific-popup', ILLUSIVE_THEME_ASSETS_URI . '/js/jquery.magnific-popup.min.js', array('jquery'), '1.0.0', FALSE);
     //custom Stye
     wp_enqueue_style(ILLUSIVE_THEME . '-style', ILLUSIVE_THEME_ASSETS_URI . '/css/' . ILLUSIVE_THEME . '.css', array('bootstarp'), ILLUSIVE_THEME_VAR);
     wp_enqueue_script(ILLUSIVE_THEME . '-js', ILLUSIVE_THEME_ASSETS_URI . '/js/' . ILLUSIVE_THEME . '.js', array('jquery'), ILLUSIVE_THEME_VAR, true);
     wp_localize_script(ILLUSIVE_THEME . '-js', 'illusive_objects', array('site_url' => get_site_url(), 'ajaxUrl' => admin_url('ajax.php'), 'mm_theme' => $illusive_redux['mobile_menu_theme'], 'mm_show_logo' => $illusive_redux['show_logo_sx'] ? TRUE : FALSE, 'mm_logo' => $illusive_redux['logo_url_sx']['url']));
 }
コード例 #3
0
function garnetmachine_scripts()
{
    $fonts = array('Roboto' => '400,100,300,500,400italic,700,900');
    wp_enqueue_style('roboto-fonts', theme_font_url($fonts), array(), null);
    wp_enqueue_style('garnetmachine-css', get_stylesheet_directory_uri() . '/css/garnetmachine.css', array('eli-css'), '20151221');
}