本文整理汇总了PHP中WP_Customize_Control::enqueue方法的典型用法代码示例。如果您正苦于以下问题:PHP WP_Customize_Control::enqueue方法的具体用法?PHP WP_Customize_Control::enqueue怎么用?PHP WP_Customize_Control::enqueue使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类WP_Customize_Control
的用法示例。
在下文中一共展示了WP_Customize_Control::enqueue方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: enqueue
/**
* This function enqueues scripts and styles
*/
public function enqueue()
{
wp_enqueue_script('sds-theme-options-customizer-color-scheme', SDS_Theme_Options::sds_core_url() . '/js/customizer-sds-theme-options-color-scheme.js', array('customize-base', 'customize-controls'), SDS_Theme_Options::get_version());
wp_localize_script('sds-theme-options-customizer-color-scheme', 'sds_color_schemes_customizer', array('color_schemes' => sds_color_schemes(), 'controls' => $this->color_controls));
// Call the parent enqueue method here
parent::enqueue();
}
示例2: enqueue
public function enqueue()
{
wp_register_style('zerowp-customizer-font-styles', plugin_dir_url(__FILE__) . 'assets/style.css');
wp_enqueue_style('zerowp-customizer-font-styles');
wp_register_script('zerowp-customizer-font-scripts', plugin_dir_url(__FILE__) . 'assets/scripts.js', 'jquery', false, true);
wp_enqueue_script('zerowp-customizer-font-scripts');
parent::enqueue();
}
示例3: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
wp_enqueue_style('switchery', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/plugins/switchery/switchery{$suffix}.css", array(), '0.7.0', 'screen');
wp_enqueue_script('switchery', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/plugins/switchery/switchery{$suffix}.js", array(), '0.7.0', true);
wp_enqueue_script('youxi-switch-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/switch-control.js", array('switchery'), YOUXI_CUSTOMIZER_VERSION, true);
}
示例4: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
if (!wp_script_is('youxi-multicheck-control')) {
wp_enqueue_script('youxi-multicheck-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/multicheck-control{$suffix}.js", array('jquery'), YOUXI_CUSTOMIZER_VERSION, true);
}
}
示例5: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
if (!wp_script_is('youxi-google-font-control')) {
wp_enqueue_script('youxi-google-font-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/google-font-control{$suffix}.js", array('jquery'), YOUXI_CUSTOMIZER_VERSION, true);
wp_localize_script('youxi-google-font-control', '_youxiCustomizeGoogleFonts', Youxi_Google_Font::fetch());
}
}
示例6: enqueue
/**
* This function enqueues scripts and styles
*/
public function enqueue()
{
// Stylesheets
// TODO
// Scripts
// TODO
// Call the parent enqueue method here
parent::enqueue();
}
示例7: enqueue
public function enqueue()
{
global $PootlePageFile;
wp_enqueue_script('wp-color-picker');
// load in footer, so will appear after WP customize-base.js and customize-controls.js
wp_enqueue_script('pootlepage-customize-controls', plugin_dir_url($PootlePageFile) . 'js/customize-controls.js', array('jquery'), false, true);
wp_enqueue_style('wp-color-picker');
wp_enqueue_style('pootlepage-customize-controls', plugin_dir_url($PootlePageFile) . 'css/customize-controls.css');
parent::enqueue();
}
示例8: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
if (!wp_style_is('youxi-range-control')) {
wp_enqueue_style('youxi-range-control', get_template_directory_uri() . '/lib/framework/customizer/controls/assets/css/range-control.css', array(), YOUXI_CUSTOMIZER_VERSION, 'screen');
}
if (!wp_script_is('youxi-range-control')) {
wp_enqueue_script('youxi-range-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/range-control{$suffix}.js", array('jquery-ui-slider'), YOUXI_CUSTOMIZER_VERSION, true);
}
}
示例9: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
if (!wp_style_is('youxi-repeater-control')) {
wp_enqueue_style('youxi-repeater-control', get_template_directory_uri() . '/lib/framework/customizer/controls/assets/css/repeater-control.css', array(), YOUXI_CUSTOMIZER_VERSION, 'screen');
}
if (!wp_script_is('youxi-repeater-control')) {
wp_enqueue_script('serializejson', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/plugins/serializejson/jquery.serializejson{$suffix}.js", array('jquery'), '2.6.1', true);
wp_enqueue_script('youxi-repeater-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/repeater-control{$suffix}.js", array('jquery', 'jquery-ui-sortable', 'serializejson', 'wp-util'), YOUXI_CUSTOMIZER_VERSION, true);
}
}
示例10: enqueue
/**
* This function enqueues scripts and styles
*/
public function enqueue()
{
// Protocol
$protocol = is_ssl() ? 'https' : 'http';
// Grab the SDS Theme Options instance
$sds_theme_options_instance = SDS_Theme_Options_Instance();
// Web Fonts
if (function_exists('sds_web_fonts')) {
$google_families = $sds_theme_options_instance->get_google_font_families_list();
wp_enqueue_style('google-web-fonts', $protocol . '://fonts.googleapis.com/css?family=' . $google_families, false, SDS_Theme_Options::get_version());
}
// Call the parent enqueue method here
parent::enqueue();
}
示例11: enqueue
public function enqueue()
{
global $PootlePageFile;
wp_enqueue_style('pootlepage-customize-controls', plugin_dir_url($PootlePageFile) . 'css/customize-controls.css');
parent::enqueue();
}
示例12: enqueue
public function enqueue()
{
parent::enqueue();
$suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
if (!wp_style_is('youxi-webfont-control')) {
wp_enqueue_style('youxi-webfont-control', get_template_directory_uri() . '/lib/framework/customizer/controls/assets/css/webfont-control.css', array(), YOUXI_CUSTOMIZER_VERSION, 'screen');
}
if (!wp_script_is('youxi-webfont-control')) {
wp_enqueue_script('youxi-webfont-control', get_template_directory_uri() . "/lib/framework/customizer/controls/assets/js/webfont-control{$suffix}.js", array('jquery', 'backbone'), YOUXI_CUSTOMIZER_VERSION, true);
wp_localize_script('youxi-webfont-control', '_youxiCustomizeWebFonts', $this->provider_js_vars());
}
}