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


PHP wpgrade::get_redux_sections方法代码示例

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


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

示例1: array

<?php

/**
 * Generate all the css declared in customizer's config
 * ====== DO NOT EDIT BELOW!!! =======
 * If you need to add custom css rules add them above so we can keep track of them
 */
$redux_sections = wpgrade::get_redux_sections();
/**
*======= TYPOGRAPHY


$fonts = array();

if ( isset( $fonts['google_menu_page_font'] ) ) {
	// this needs a default
	$font_size = '14px'; ?>
	html body.jassy_menu_page p, html body.jassy_menu_page span, html body.jassy_menu_page h4, html body.jassy_menu_page h2 {
	<?php wpgrade::display_font_params( $fonts['google_menu_page_font'] ); ?>
	}
<?php }
*/
//handle the complicated logic of the footer waves that keeps changing color
$footer_sidebar_style = wpgrade::option('footer_sidebar_style');
$waves_fill_color = '#121212';
switch ($footer_sidebar_style) {
    case 'light':
        $waves_fill_color = '#ffffff';
        break;
    case 'dark':
        $waves_fill_color = '#121212';
开发者ID:andreilupu,项目名称:jassyro-rosa-child-theme,代码行数:31,代码来源:inline-custom-css.php

示例2: reset_style_section

 /**
  * This is a wpgrade specific hook!
  * @TODO Maybe refactor it in the future to work in redux extension
  */
 public function reset_style_section()
 {
     check_ajax_referer('reset-style-section', 'security');
     $defaults = wpgrade::get_redux_defaults();
     $sections = wpgrade::get_redux_sections();
     if (!empty($sections)) {
         foreach ($sections as $section) {
             if (isset($section['type']) && $section['type'] == 'customizer_section' && isset($section['fields']) && !empty($section['fields'])) {
                 foreach ($section['fields'] as $field) {
                     if (isset($field['id']) && isset($defaults[$field['id']])) {
                         $default_value = $defaults[$field['id']];
                         wpgrade::setoption($field['id'], $default_value);
                     }
                 }
             }
         }
     }
 }
开发者ID:pwzCypher,项目名称:wp-push,代码行数:22,代码来源:extension_customizer.php


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