• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP is_store_notice_showing函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中is_store_notice_showing函数的典型用法代码示例。如果您正苦于以下问题:PHP is_store_notice_showing函数的具体用法?PHP is_store_notice_showing怎么用?PHP is_store_notice_showing使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



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

示例1: wise_woocommerce_demo_store

 function wise_woocommerce_demo_store()
 {
     if (get_option('woocommerce_demo_store_notice') == null) {
         return;
     }
     $notice = get_option('woocommerce_demo_store_notice');
     if (function_exists('is_woocommerce') && is_woocommerce() && $notice != null && is_store_notice_showing()) {
         echo apply_filters('woocommerce_demo_store', '<div class="alert"><p class="demo_store">' . wp_kses_post($notice) . '<a href="#" class="close" data-dismiss="alert" aria-label="close">&times;</a></p></div>');
     } else {
         echo apply_filters('woocommerce_demo_store', '<p class="demo_store" style="display:none;">' . wp_kses_post($notice) . '</p>');
     }
 }
开发者ID:Falkvinge,项目名称:BlogTheme2016,代码行数:12,代码来源:additional-functions.php


示例2: woocommerce_demo_store

 /**
  * Adds a demo store banner to the site if enabled
  *
  * @access public
  * @return void
  */
 function woocommerce_demo_store()
 {
     if (!is_store_notice_showing()) {
         return;
     }
     $notice = get_option('woocommerce_demo_store_notice');
     if (empty($notice)) {
         $notice = __('This is a demo store for testing purposes &mdash; no orders shall be fulfilled.', 'woocommerce');
     }
     echo apply_filters('woocommerce_demo_store', '<p class="demo_store">' . $notice . '</p>');
 }
开发者ID:uwitec,项目名称:findgreatmaster,代码行数:17,代码来源:wc-template-functions.php


示例3: test_is_store_notice_showing

 /**
  * Test is_store_notice_showing().
  *
  * @since 2.3.0
  */
 public function test_is_store_notice_showing()
 {
     $this->assertEquals(false, is_store_notice_showing());
 }
开发者ID:bitoncoin,项目名称:woocommerce,代码行数:9,代码来源:conditional-functions.php


示例4: woocommerce_demo_store

 /**
  * Adds a demo store banner to the site if enabled.
  *
  */
 function woocommerce_demo_store()
 {
     if (!is_store_notice_showing()) {
         return;
     }
     $notice = get_option('woocommerce_demo_store_notice');
     if (empty($notice)) {
         $notice = __('This is a demo store for testing purposes &mdash; no orders shall be fulfilled.', 'woocommerce');
     }
     echo apply_filters('woocommerce_demo_store', '<p class="woocommerce-store-notice demo_store">' . wp_kses_post($notice) . ' <a href="#" class="woocommerce-store-notice__dismiss-link">' . __('Dismiss', 'woocommerce') . '</a></p>', $notice);
 }
开发者ID:woocommerce,项目名称:woocommerce,代码行数:15,代码来源:wc-template-functions.php


示例5: woocommerce_site_note

 /**
  * Adds a demo store banner to the site if enabled
  *
  */
 function woocommerce_site_note()
 {
     if (!is_store_notice_showing()) {
         return;
     }
     $notice = get_option('woocommerce_demo_store_notice');
     if (empty($notice)) {
         $notice = __('This is a demo store for testing purposes &mdash; no orders shall be fulfilled.', 'woocommerce');
     }
     echo '<div class="alert alert-info">' . wp_kses_post($notice) . '</div>';
 }
开发者ID:ntngiri,项目名称:Wordpress-dhaba,代码行数:15,代码来源:woocommerce.php


示例6: wp_get_sidebars_widgets

 * Used for single page.
 *
 * @package WordPress
 * @subpackage Krypton
 * @since Krypton 1.0
 */
global $krypton_config, $post;
$woocommerce = "";
$sidebars = wp_get_sidebars_widgets();
$sidebar = false;
if (isset($sidebars['krypton-sidebar']) && count($sidebars['krypton-sidebar'])) {
    $sidebar = 'krypton-sidebar';
} elseif (isset($sidebars['sidebar-1']) && !isset($sidebars['krypton-sidebar']) && count($sidebars['sidebar-1'])) {
    $sidebar = 'sidebar-1';
}
if (is_plugin_active('woocommerce/woocommerce.php') && (is_woocommerce() || is_checkout() || is_cart() || is_account_page() || is_store_notice_showing())) {
    $woocommerce = "shop";
    if (isset($sidebars['shop-sidebar']) && count($sidebars['shop-sidebar'])) {
        $sidebar = 'shop-sidebar';
    }
}
get_header($woocommerce);
$sidebar_position = get_post_meta(get_the_ID(), 'sidebar_position', true);
if (!isset($sidebar_position) || empty($sidebar_position) || $sidebar_position == 'default') {
    switch ($krypton_config['layout']) {
        case 1:
            $sidebar_position = "nosidebar";
            break;
        case 2:
            $sidebar_position = "sidebar-left";
            break;
开发者ID:estrategasdigitales,项目名称:lactibox,代码行数:31,代码来源:page.php


示例7: is_store_notice_showing

 public static function is_store_notice_showing()
 {
     return self::exists() && is_store_notice_showing();
 }
开发者ID:brutalenemy666,项目名称:wp-utils,代码行数:4,代码来源:class-wc.php



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


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP is_string函数代码示例发布时间:2022-05-15
下一篇:
PHP is_sticky函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap