本文整理汇总了PHP中ya_options函数的典型用法代码示例。如果您正苦于以下问题:PHP ya_options函数的具体用法?PHP ya_options怎么用?PHP ya_options使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了ya_options函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: Ya_SelectMenu_Filter
function Ya_SelectMenu_Filter($args)
{
//var_dump($args);
$args['container'] = false;
$ya_theme_locate = ya_options()->getCpanelValue('menu_location');
$ya_menu_class = ya_options()->getCpanelValue('menu_visible');
if (strcmp($ya_theme_locate, $args['theme_location']) == 0) {
$args['menu_class'] = 'ya_selectmenu ' . $ya_menu_class;
$args['walker'] = new YA_Menu_Select();
$args['items_wrap'] = '<select class="%2$s">%3$s</select>';
}
return $args;
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:13,代码来源:ya-menu-select.php
示例2: ya_google_analytics
function ya_google_analytics()
{
?>
<script>
var _gaq=[['_setAccount','<?php
echo ya_options()->getCpanelValue('google_analytics_id');
?>
'],['_trackPageview']];
(function(d,t){var g=d.createElement(t),s=d.getElementsByTagName(t)[0];
g.src=('https:'==location.protocol?'//ssl':'//www')+'.google-analytics.com/ga.js';
s.parentNode.insertBefore(g,s)}(document,'script'));
</script>
<?php
}
开发者ID:pqzada,项目名称:avispate,代码行数:15,代码来源:scripts.php
示例3: ya_nav_menu_args
/**
* Clean up wp_nav_menu_args
*
* Remove the container
* Use YA_Menu_Walker() by default
*/
function ya_nav_menu_args($args = '')
{
$ya_nav_menu_args['container'] = false;
if (!$args['items_wrap']) {
$ya_nav_menu_args['items_wrap'] = '<ul class="%2$s">%3$s</ul>';
}
if (!$args['walker']) {
if ('mega' == ya_options()->getCpanelValue('menu_type')) {
$ya_nav_menu_args['walker'] = new YA_Mega_Menu_Walker();
} else {
$ya_nav_menu_args['walker'] = new YA_Menu_Walker();
}
}
return array_merge($args, $ya_nav_menu_args);
}
开发者ID:pqzada,项目名称:avispate,代码行数:21,代码来源:nav.php
示例4: ya_body_class
/**
* Add and remove body_class() classes
*/
function ya_body_class($classes)
{
$direction = ya_options()->getCpanelValue('direction');
if ($direction == 'rtl') {
$classes[] = 'rtl';
}
// Add post/page slug
if (is_single() || is_page() && !is_front_page()) {
$classes[] = basename(get_permalink());
}
// Remove unnecessary classes
$home_id_class = 'page-id-' . get_option('page_on_front');
$remove_classes = array('page-template-default', $home_id_class);
$classes = array_diff($classes, $remove_classes);
return $classes;
}
开发者ID:pqzada,项目名称:avispate,代码行数:19,代码来源:cleanup.php
示例5: Ya_MenuRes_Filter
function Ya_MenuRes_Filter($args)
{
//var_dump($args);
$args['container'] = false;
$ya_theme_locate = ya_options()->getCpanelValue('menu_location');
$ya_menu_class = ya_options()->getCpanelValue('menu_visible');
if (strcmp($ya_theme_locate, $args['theme_location']) == 0) {
$args['container'] = 'div';
$args['container_class'] .= 'resmenu-container ' . $ya_menu_class;
$args['items_wrap'] = '<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#ResMenu">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button><div id="ResMenu" class="collapse menu-responsive-wrapper"><ul id="%1$s" class="%2$s">%3$s</ul></div>';
$args['menu_class'] = 'ya_resmenu';
$args['walker'] = new YA_ResMenu_Walker();
}
return $args;
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:20,代码来源:ya_responsive_menu.php
示例6: ya_parse_request
function ya_parse_request(&$wp)
{
global $add_query_vars, $options_args;
if (is_array($add_query_vars)) {
foreach ($add_query_vars as $field) {
if (array_key_exists($field, $wp->query_vars)) {
$current_value = ya_options()->get($field);
$request_value = $wp->query_vars[$field];
$field_name = $options_args['opt_name'] . '_' . $field;
if ($request_value != $current_value) {
setcookie($field_name, $request_value, time() + 86400, '/', COOKIE_DOMAIN, 0);
if (!isset($_COOKIE[$field_name]) || $request_value != $_COOKIE[$field_name]) {
$_COOKIE[$field_name] = $request_value;
}
//$url = curPageURL();
//header("Refresh: 0; url=$url");
//exit();
}
}
}
}
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:22,代码来源:options.php
示例7: in_widget_form
public function in_widget_form($widget, $r = null, $instance = array())
{
//Logger::log(__CLASS__.'::'.__FUNCTION__);
//Logger::log( array_merge( array('instance' => get_class($widget)), $instance) );
$widget_advanced = ya_options()->getCpanelValue('widget-advanced');
if (!$widget_advanced) {
return;
}
$this->widget =& $widget;
//$widget_class_suffix = isset($instance['widget_class_suffix']) ? $instance['widget_class_suffix'] : '';
$widget_style = isset($instance['widget_style']) ? trim($instance['widget_style']) : '';
$adoptions = isset($instance['adoptions']) ? $instance['adoptions'] : false;
$adoptions_checked = $adoptions ? 'checked="checked"' : '';
$adoptions_on_class = $adoptions ? 'on' : '';
//Widgets Style
$styles = $this->getWidgetStyles();
$styles = array_merge(array('default' => 'Default'), $styles);
$styles = array_unique($styles);
//Widget Display
$widget_display = isset($instance['widget_display']) ? $instance['widget_display'] : array();
?>
<div class="advanced-opt <?php
echo $adoptions_on_class;
?>
">
<div class="advanced-opt-controls" >
<label class="button toggle" for="<?php
echo $widget->get_field_id('adoptions');
?>
">Advanced Options
<input type="checkbox" class="pane-toggler" <?php
echo $adoptions_checked;
?>
style="display: none;" name="<?php
echo $widget->get_field_name('adoptions');
?>
" id="<?php
echo $widget->get_field_id('adoptions');
?>
">
</label>
</div>
<div class="advanced-opt-pane">
<div class="advanced-opt-pane-inner">
<div class="pane-content">
<div class="pane-left">
<p>
<label for="<?php
echo $widget->get_field_id('widget_style');
?>
"><?php
_e('Widget Style', 'yatheme');
?>
</label> <select class="widefat"
id="<?php
echo $widget->get_field_id('widget_style');
?>
"
name="<?php
echo $widget->get_field_name('widget_style');
?>
">
<?php
foreach ($styles as $key => $value) {
$selected = '';
if ($key == $widget_style) {
$selected = 'selected="selected"';
}
?>
<option <?php
echo 'value="' . $key . '" ' . $selected;
?>
>
<?php
echo $value;
?>
</option>
<?php
}
?>
</select>
</p>
<?php
echo $this->render_wdisplay($widget_display);
?>
</div>
<div class="pane-right"></div>
</div>
</div>
</div>
<br class="clear">
</div>
<?php
}
开发者ID:pqzada,项目名称:avispate,代码行数:96,代码来源:widgets.php
示例8: ya_customize_register
/**
* Adds sections to the customizer
* @param WP_Customize_Control $wp_customize
*/
function ya_customize_register($wp_customize)
{
$priority = 200;
$sections = array();
$ya_options = ya_options();
$i = 0;
foreach ($ya_options->sections as $section) {
if (isset($section['fields']) && is_array($section['fields'])) {
foreach ($section['fields'] as $field) {
$customize = $field['id'] . '_customize_allow';
if ($ya_options->get($customize)) {
if (isset($field['options'])) {
$field['choices'] = $field['options'];
}
if ($field['type'] == 'upload') {
$field['type'] = 'image';
}
if ($field['type'] == 'radio_img') {
$field['type'] = 'select';
$field['choices'] = array();
foreach ($field['options'] as $key => $choices) {
$field['choices'][$key] = $choices['title'];
}
}
$field['label'] = $field['title'];
$field['section'] = sanitize_title($section['title']);
$field['settings'] = $ya_options->args['opt_name'] . '[' . $field['id'] . ']';
$field['priority'] = $priority++;
$sections[$i]['fields'][] = $field;
}
}
if (isset($sections[$i]['fields'])) {
$sections[$i]['title'] = $section['title'];
$sections[$i]['priority'] = $priority++;
$sections[$i]['capability'] = 'edit_theme_options';
$i++;
}
}
}
foreach ($sections as $section) {
// Add Section
$wp_customize->add_section(sanitize_title($section['title']), $section);
foreach ($section['fields'] as $field) {
//Add Setting
$wp_customize->add_setting($ya_options->args['opt_name'] . '[' . $field['id'] . ']', array('default' => $ya_options->get($field['id']), 'type' => 'option', 'transport' => 'postMessage', 'capability' => 'edit_theme_options', 'sanitize_callback' => 'customize_option'));
// Add Control
switch ($field['type']) {
case 'color':
$wp_customize->add_control(new WP_Customize_Color_Control($wp_customize, $field['id'], $field));
break;
case 'image':
$wp_customize->add_control(new WP_Customize_Image_Control($wp_customize, $field['id'], $field));
break;
case 'textarea':
$wp_customize->add_control(new WP_Customize_Textarea_Control($wp_customize, $field['id'], $field));
break;
default:
$wp_customize->add_control($field['id'], $field);
}
//$wp_customize->get_setting($ya_options->args['opt_name'].'['.$field['id'].']')->transport = 'postMessage';
}
}
$wp_customize->get_setting('blogname')->transport = 'postMessage';
$wp_customize->get_setting('blogdescription')->transport = 'postMessage';
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:69,代码来源:customizer.php
示例9: locate_template
require_once locate_template('/lib/plugins/currency-converter/currency-converter.php');
// currency converter
if (ya_options()->getCpanelValue('menu_type') == 'mega') {
function stop_removing_core_classes()
{
remove_filter('nav_menu_css_class', 'ya_nav_menu_css_class', 10, 2);
remove_filter('nav_menu_item_id', '__return_null');
}
add_action('init', 'stop_removing_core_classes');
require_once locate_template('/lib/ubermenu/ubermenu.php');
}
require_once locate_template('/lib/less.php');
// Custom functions
//active revolution slider
$revslider = get_template_directory() . '/lib/revslider/revslider.php';
if (!ya_options()->getCpanelValue('revslide_active')) {
include $revslider;
// Activate the plugin if necessary
if (get_option('ya_revslider_activated', '0') == '0') {
if (!class_exists('RevSliderAdmin')) {
$revslider_admin_script = get_template_directory() . '/lib/revslider/revslider_admin.php';
include $revslider_admin_script;
}
// Run activation script
$revslider_admin = new RevSliderAdmin($revslider);
$revslider_admin->onActivate();
// Save a flag that it is activated, so this won't run again
update_option('ya_revslider_activated', '1');
}
}
/* Disable WordPress Admin Bar for all users but admins. */
开发者ID:pqzada,项目名称:avispate,代码行数:31,代码来源:functions.php
示例10: ya_options
*
* @author WooThemes
* @package WooCommerce/Templates
* @version 2.4.0
*/
if (!defined('ABSPATH')) {
exit;
}
// Exit if accessed directly
global $product, $woocommerce_loop, $post;
if (empty($woocommerce_loop['loop'])) {
$woocommerce_loop['loop'] = 0;
}
$col_lg = ya_options()->getCpanelValue('product_col_large');
$col_md = ya_options()->getCpanelValue('product_col_medium');
$col_sm = ya_options()->getCpanelValue('product_col_sm');
$column1 = 12 / $col_md;
$column2 = 12 / $col_sm;
$class_col = "";
$col_large = 0;
// Store column count for displaying the grid
if (empty($woocommerce_loop['columns'])) {
$col_large = 12 / $col_lg;
} else {
$col_large = 12 / $woocommerce_loop['columns'];
}
// Ensure visibility
if (!$product || !$product->is_visible()) {
return;
}
// Increase loop count
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:31,代码来源:content-product.php
示例11: ya_layout_class
function ya_layout_class($classes)
{
$header = ya_options()->getCpanelValue('box_layout');
if ($header == 'box') {
$classes[] = 'boxed';
}
// return the $classes array
return $classes;
}
开发者ID:pqzada,项目名称:avispate,代码行数:9,代码来源:utils.php
示例12: ya_content_blog
}
?>
<div class="single main <?php
ya_content_blog();
?>
" >
<?php
get_template_part('templates/content', 'single');
?>
</div>
<?php
if (is_active_sidebar_YA('right-blog') && $sidebar_template != 'left_sidebar' && $sidebar_template != 'full') {
$right_span_class = 'col-lg-' . ya_options()->getCpanelValue('sidebar_right_expand');
$right_span_class .= ' col-md-' . ya_options()->getCpanelValue('sidebar_right_expand_md');
$right_span_class .= ' col-sm-' . ya_options()->getCpanelValue('sidebar_right_expand_sm');
?>
<aside id="right" class="sidebar <?php
echo esc_attr($right_span_class);
?>
">
<?php
dynamic_sidebar('right-blog');
?>
</aside>
<?php
}
?>
</div>
</div>
</div>
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:31,代码来源:single.php
示例13: colorset
function colorset($atts)
{
$value = ya_options()->getCpanelValue('scheme');
return $value;
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:5,代码来源:shortcodes.php
示例14: get_template_part
<?php
if (!have_posts()) {
get_template_part('templates/no-results');
}
$blog_columns = ya_options()->getCpanelValue('blog_column');
$col = 'col-sm-' . 12 / $blog_columns . ' theme-clearfix';
global $instance;
?>
<div class="row grid-blog">
<?php
while (have_posts()) {
the_post();
$format = get_post_format();
global $post;
?>
<div id="post-<?php
the_ID();
?>
" <?php
post_class($col);
?>
>
<div class="entry clearfix">
<?php
if ($format == '') {
?>
<?php
if (get_the_post_thumbnail()) {
?>
<div class="entry-thumb">
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:31,代码来源:content-grid.php
示例15: array
?>
</div>
</div>
<div class="container">
<?php
$portfolio = array();
$attributes = '';
$number = 8;
$orderby = 'date';
$order = '';
$portfolio_id = ya_options()->getCpanelValue('portfolio_id');
$style = ya_options()->getCpanelValue('p_style');
$col1 = ya_options()->getCpanelValue('p_col_large');
$col2 = ya_options()->getCpanelValue('p_col_medium');
$col3 = ya_options()->getCpanelValue('p_col_sm');
$col4 = ya_options()->getCpanelValue('p_col_xs');
$pf_id = 'ya_portfolio';
if (count($portfolio_id) > 0) {
$portfolio = $portfolio_id;
} else {
$terms = get_terms('portfolio_cat');
foreach ($terms as $k => $term) {
$portfolio[$k] = $term->term_id;
}
}
include plugin_dir_path(__FILE__) . 'portfolio-item.php';
?>
</div>
<?php
get_footer();
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:31,代码来源:portfolio-archive.php
示例16: ya_scripts
/**
* Enqueue scripts and stylesheets
*
*/
function ya_scripts()
{
$scheme = ya_options()->getCpanelValue('scheme');
if ($scheme) {
$app_css = get_template_directory_uri() . '/css/app-' . $scheme . '.css';
} else {
$app_css = get_template_directory_uri() . '/css/app-default.css';
}
wp_register_style('bootstrap', get_template_directory_uri() . '/css/bootstrap.min.css', array(), null);
wp_register_style('ya_photobox_css', get_template_directory_uri() . '/css/photobox.css', array(), null);
wp_register_style('rtl_css', get_template_directory_uri() . '/css/rtl.css', array(), null);
wp_register_style('yatheme_css', $app_css, array(), null);
wp_register_style('flexslider_css', get_template_directory_uri() . '/css/flexslider.css', array(), null);
wp_register_style('respslider_css', get_template_directory_uri() . '/css/slick.css', array(), null);
wp_register_style('lightbox_css', get_template_directory_uri() . '/css/jquery.fancybox.css', array(), null);
wp_register_style('animate_css', get_template_directory_uri() . '/css/animate.css', array(), null);
wp_register_style('yatheme_responsive_css', get_template_directory_uri() . '/css/app-responsive.css', array('yatheme_css'), null);
/* register script */
wp_register_script('modernizr', get_template_directory_uri() . '/js/modernizr-2.6.2.min.js', false, null, false);
wp_register_script('bootstrap_js', get_template_directory_uri() . '/js/bootstrap.min.js', array('jquery'), null, true);
wp_register_script('bootstrap_responsive_js', get_template_directory_uri() . '/js/responsive-tabs.js', array('jquery'), null, true);
wp_register_script('gallery_load_js', get_template_directory_uri() . '/js/load-image.min.js', array('bootstrap_js'), null, true);
wp_register_script('bootstrap_gallery_js', get_template_directory_uri() . '/js/bootstrap-image-gallery.min.js', array('gallery_load_js'), null, true);
wp_register_script('flexslider_js', get_template_directory_uri() . '/js/jquery.flexslider-min.js', array('jquery'), null, true);
wp_register_script('photobox_js', get_template_directory_uri() . '/js/photobox.js', array('jquery'), null, true);
wp_register_script('plugins_js', get_template_directory_uri() . '/js/plugins.js', array('jquery'), null, true);
wp_register_script('lightbox_js', get_template_directory_uri() . '/js/jquery.fancybox.pack.js', array('jquery'), null, true);
wp_register_script('ya_circle_skill', get_template_directory_uri() . '/js/jquery.circliful.min.js', array(), null, true);
wp_register_script('ya_accordion', get_template_directory_uri() . '/js/jquery.accordion.js', array(), null, true);
wp_register_script('ya_countup', get_template_directory_uri() . '/js/jquery.counterup.js', array(), null, true);
wp_register_script('slick_slider_js', get_template_directory_uri() . '/js/slick.min.js', array(), null, true);
wp_register_script('woo_countdown_js', get_template_directory_uri() . '/js/jquery.countdown.min.js', array(), null, true);
wp_register_script('cloud-zoom', get_template_directory_uri() . '/js/cloud-zoom.1.0.2.min.js', array(), null, true);
wp_register_script('masonry_js', get_template_directory_uri() . '/js/isotope.js', array(), null, true);
wp_register_script('number_js', get_template_directory_uri() . '/js/number-polyfill.min.js', array('jquery'), null, true);
wp_register_script('animate_js', get_template_directory_uri() . '/js/wow.min.js', array(), null, true);
wp_register_script('quantity_js', get_template_directory_uri() . '/js/wc-quantity-increment.min.js', array('jquery'), null, true);
wp_register_script('hoverdir', get_template_directory_uri() . '/js/jquery.hoverdir.js', array(), null, true);
wp_register_script('megamenu_js', get_template_directory_uri() . '/js/megamenu.js', array(), null, true);
wp_register_script('yatheme_js', get_template_directory_uri() . '/js/main.js', array('bootstrap_js', 'plugins_js'), null, true);
/* enqueue script & style */
if (!is_admin()) {
wp_dequeue_style('tabcontent_styles');
wp_enqueue_style('bootstrap');
if (is_rtl() || ($ya_direction = 'rtl')) {
wp_enqueue_style('rtl_css');
}
wp_enqueue_script('lightbox_js');
wp_enqueue_script('lightbox_js');
wp_enqueue_script('ya_circle_skill');
wp_enqueue_script('ya_countup');
wp_enqueue_style('flexslider_css');
wp_enqueue_style('slick_css');
wp_enqueue_style('lightbox_css');
wp_enqueue_style('yatheme_css');
wp_enqueue_style('animate_css');
wp_enqueue_script('flexslider_js');
wp_enqueue_script('slick');
wp_enqueue_script('masonry_js');
wp_enqueue_script('cloud-zoom');
wp_enqueue_script('number_js');
wp_enqueue_script('animate_js');
wp_enqueue_script('quantity_js');
wp_enqueue_script('hoverdir');
wp_enqueue_script('bootstrap_responsive_js');
if (ya_options()->getCpanelValue('responsive_support')) {
/* wp_enqueue_style('bootstrap_responsive_css'); */
wp_enqueue_style('yatheme_responsive_css');
}
/* is_rtl() && wp_enqueue_style('bootstrap_rtl_css'); */
/* Load style.css from child theme */
if (is_child_theme()) {
wp_enqueue_style('yatheme_child_css', get_stylesheet_uri(), false, null);
}
}
if (is_single() && comments_open() && get_option('thread_comments')) {
wp_enqueue_script('comment-reply');
}
$is_category = is_category() && !is_category('blog');
if (!is_admin()) {
wp_enqueue_script('modernizr');
wp_enqueue_script('yatheme_js');
}
if (ya_options()->getCpanelValue('effect_active') == 1) {
if (is_home() || is_front_page()) {
wp_enqueue_script('scroll_js');
}
}
if (ya_options()->getCpanelValue('menu_type') == 'mega') {
wp_enqueue_script('megamenu_js');
}
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:96,代码来源:scripts.php
示例17: while
<?php
while (have_posts()) {
the_post();
$related_post_column = ya_options()->getCpanelValue('sidebar_blog');
?>
<?php
setPostViews(get_the_ID());
?>
<div <?php
post_class();
?>
>
<?php
$pfm = get_post_format();
?>
<header class="header-single">
</header>
<div class="entry-content">
<?php
if ($pfm == '' || $pfm == 'image') {
?>
<?php
if (has_post_thumbnail()) {
?>
<div class="single-thumb">
<?php
the_post_thumbnail('ya_detail_thumb');
?>
</div>
<?php
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:31,代码来源:content-single.php
示例18: ya_popup
function ya_popup()
{
$ya_popup = ya_options()->getCpanelValue('popup_active');
$ya_popup_content = ya_options()->getCpanelValue('popup_shortcode');
if ($ya_popup) {
echo stripslashes(do_shortcode($ya_popup_content));
?>
<script>
(function($) {
$(document).ready(function() {
var check_cookie = $.cookie('subscribe_popup');
if(check_cookie == null || check_cookie == 'shown') {
popupNewsletter();
}
$('#subscribe_popup input#popup_check').on('click', function(){
if($(this).parent().find('input:checked').length){
var check_cookie = $.cookie('subscribe_popup');
if(check_cookie == null || check_cookie == 'shown') {
$.cookie('subscribe_popup','dontshowitagain');
}
else
{
$.cookie('subscribe_popup','shown');
popupNewsletter();
}
} else {
$.cookie('subscribe_popup','shown');
}
});
});
function popupNewsletter() {
jQuery.fancybox({
href: '#subscribe_popup',
autoResize: true
});
jQuery('#subscribe_popup').trigger('click');
jQuery('#subscribe_popup').parents('.fancybox-overlay').addClass('popup-fancy');
};
}(jQuery));
</script>
<?php
}
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:44,代码来源:cleanup.php
示例19: ya_direction
function ya_direction($doctype = 'html')
{
$ya_direction = ya_options()->getCpanelValue('direction');
if (function_exists('is_rtl') && is_rtl() || $ya_direction == 'rtl') {
$ya_attribute[] = 'dir="rtl"';
}
$ya_direction === 'rtl' ? $lang = 'ar' : ($lang = get_bloginfo('language'));
if ($lang) {
if (get_option('html_type') == 'text/html' || $doctype == 'html') {
$ya_attribute[] = "lang=\"{$lang}\"";
}
if (get_option('html_type') != 'text/html' || $doctype == 'xhtml') {
$ya_attribute[] = "xml:lang=\"{$lang}\"";
}
}
$ya_output = implode(' ', $ya_attribute);
return $ya_output;
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:18,代码来源:utils.php
示例20: ya_product_category_class
function ya_product_category_class($classes, $category = null)
{
$ya_product_sidebar = ya_options()->getCpanelValue('sidebar_product');
if ($ya_product_sidebar == 'left' || $ya_product_sidebar == 'right') {
$classes[] = 'col-lg-4 col-md-4 col-sm-6 col-xs-6 col-mb-12';
} else {
if ($ya_product_sidebar == 'lr') {
$classes[] = 'col-lg-6 col-md-6 col-sm-6 col-xs-6 col-mb-12';
} else {
if ($ya_product_sidebar == 'full') {
$classes[] = 'col-lg-3 col-md-4 col-sm-6 col-xs-6 col-mb-12';
}
}
}
return $classes;
}
开发者ID:junibrosas,项目名称:shoppingyourway,代码行数:16,代码来源:woocommerce-hook.php
注:本文中的ya_options函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论