当前位置: 首页>>代码示例>>PHP>>正文


PHP WP_Customize_Image_Control::enqueue方法代码示例

本文整理汇总了PHP中WP_Customize_Image_Control::enqueue方法的典型用法代码示例。如果您正苦于以下问题:PHP WP_Customize_Image_Control::enqueue方法的具体用法?PHP WP_Customize_Image_Control::enqueue怎么用?PHP WP_Customize_Image_Control::enqueue使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在WP_Customize_Image_Control的用法示例。


在下文中一共展示了WP_Customize_Image_Control::enqueue方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: enqueue

 /**
  * @access public
  */
 public function enqueue()
 {
     wp_enqueue_media();
     wp_enqueue_script('customize-views');
     $this->prepare_control();
     wp_localize_script('customize-views', '_wpCustomizeHeader', array('data' => array('width' => absint(get_theme_support('custom-header', 'width')), 'height' => absint(get_theme_support('custom-header', 'height')), 'flex-width' => absint(get_theme_support('custom-header', 'flex-width')), 'flex-height' => absint(get_theme_support('custom-header', 'flex-height')), 'currentImgSrc' => $this->get_current_image_src()), 'nonces' => array('add' => wp_create_nonce('header-add'), 'remove' => wp_create_nonce('header-remove')), 'uploads' => $this->uploaded_headers, 'defaults' => $this->default_headers));
     parent::enqueue();
 }
开发者ID:AndreyLanko,项目名称:perevorot-prozorro-wp,代码行数:11,代码来源:class-wp-customize-header-image-control.php

示例2: enqueue

 /**
  * This function enqueues scripts and styles
  */
 public function enqueue()
 {
     wp_enqueue_media();
     // Enqueue media scripts
     wp_enqueue_script('sds-theme-options-customizer-logo', get_template_directory_uri() . '/includes/js/customizer-sds-theme-options-logo.js', array('customize-base', 'customize-controls'), SDS_Theme_Options::VERSION);
     // Call the parent enqueue method here
     parent::enqueue();
 }
开发者ID:se7ven214,项目名称:Kungfuphp.local,代码行数:11,代码来源:class-sds-theme-options-customize-logo-control.php

示例3: enqueue

 /**
  * This function enqueues scripts and styles
  */
 public function enqueue()
 {
     wp_enqueue_media();
     // Enqueue media scripts
     wp_enqueue_script('sds-theme-options-customizer-logo', SDS_Theme_Options::sds_core_url() . '/js/customizer-sds-theme-options-logo.js', array('customize-base', 'customize-controls'), SDS_Theme_Options::get_version());
     // Call the parent enqueue method here
     parent::enqueue();
 }
开发者ID:sdsweb,项目名称:baton,代码行数:11,代码来源:class-sds-theme-options-customize-logo-control.php

示例4: enqueue

 /**
  * Enqueue control related scripts/styles.
  *
  * @since 4.3.0
  * @access public
  */
 public function enqueue()
 {
     wp_enqueue_script('customize-views');
     parent::enqueue();
 }
开发者ID:AndreyLanko,项目名称:perevorot-prozorro-wp,代码行数:11,代码来源:class-wp-customize-cropped-image-control.php

示例5: enqueue

 /**
  * Enqueue control related scripts/styles.
  *
  * @since 4.1.0
  */
 public function enqueue()
 {
     parent::enqueue();
     $custom_background = get_theme_support('custom-background');
     wp_localize_script('customize-controls', '_wpCustomizeBackground', array('defaults' => !empty($custom_background[0]) ? $custom_background[0] : array(), 'nonces' => array('add' => wp_create_nonce('background-add'))));
 }
开发者ID:aaemnnosttv,项目名称:develop.git.wordpress.org,代码行数:11,代码来源:class-wp-customize-background-image-control.php

示例6: enqueue

 /**
  * Enqueue control related scripts/styles.
  *
  * @since 4.1.0
  */
 public function enqueue()
 {
     parent::enqueue();
     wp_localize_script('customize-controls', '_wpCustomizeBackground', array('nonces' => array('add' => wp_create_nonce('background-add'))));
 }
开发者ID:AndreyLanko,项目名称:perevorot-prozorro-wp,代码行数:10,代码来源:class-wp-customize-background-image-control.php


注:本文中的WP_Customize_Image_Control::enqueue方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。