本文整理汇总了PHP中rehub_option函数的典型用法代码示例。如果您正苦于以下问题:PHP rehub_option函数的具体用法?PHP rehub_option怎么用?PHP rehub_option使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了rehub_option函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: rehub_create_affiliate_link
$link_on_thumb = $affiliate_link != '' ? rehub_create_affiliate_link() : get_the_permalink();
?>
<?php
$link_on_thumb_target = $affiliate_link != '' ? ' class="btn_offer_block" target="_blank" rel="nofollow"' : '';
?>
<a href="<?php
echo $link_on_thumb;
?>
"<?php
echo $link_on_thumb_target;
?>
>
<?php
$img = get_post_thumb();
$nothumb = get_template_directory_uri() . '/images/default/noimage_100_70.png';
if (rehub_option('aq_resize_crop') == '1') {
$params = array('width' => 100);
} else {
$params = array('width' => 100, 'height' => 100, 'crop' => true);
}
?>
<?php
if (!empty($img)) {
?>
<img src="<?php
echo bfi_thumb($img, $params);
?>
" alt="<?php
the_title_attribute();
?>
" />
示例2: the_permalink
<div><a href="<?php
the_permalink();
?>
" class="read_full" target="_blank"><?php
if (rehub_option('rehub_review_text') != '') {
echo rehub_option('rehub_review_text');
} else {
_e('Read review', 'rehub_framework');
}
?>
</a></div>
示例3: attach_comment_criteria_raitings
function attach_comment_criteria_raitings($text = '')
{
$userCriteria = get_comment_meta(get_comment_ID(), 'user_criteria', true);
$pros_review = get_comment_meta(get_comment_ID(), 'pros_review', true);
$cons_review = get_comment_meta(get_comment_ID(), 'cons_review', true);
$userAverage = get_comment_meta(get_comment_ID(), 'user_average', true);
if (is_array($userCriteria) && !empty($userCriteria)) {
if (rehub_option('color_type_review') == 'simple') {
$color_type = ' simple_color';
} else {
$color_type = ' multi_color';
}
if (is_singular('post') && rehub_option('rehub_replace_color') == '1' && rehub_option('color_type_review') == 'simple') {
$category = get_the_category($post->ID);
$first_cat = $category[0]->term_id;
$cat_sustom = ' category-' . $first_cat . '';
} else {
$cat_sustom = '';
}
$text = '<div class="user_reviews_view' . $color_type . '' . $cat_sustom . '"><div class="user_reviews_view_left">';
if (isset($userAverage) && $userAverage != '') {
$userAverages = $userAverage * 10;
$userstartitle = $userAverage / 2;
$text .= '<div class="user_reviews_view_score"><div class="userstar-rating" title="' . __('Rated', 'rehub_framework') . ' ' . $userstartitle . ' ' . __('out of', 'rehub_framework') . ' 5"><span style="width:' . $userAverages . '%"><strong class="rating">' . $userstartitle . '</strong></span></div></div>';
}
for ($i = 0; $i < count($userCriteria); $i++) {
$value_criteria = $userCriteria[$i]['value'] * 10;
$text .= '<div class="user_reviews_view_criteria_line"><span class="user_reviews_view_criteria_name">' . $userCriteria[$i]['name'] . '</span><div class="userstar-rating"><span style="width:' . $value_criteria . '%"><strong class="rating">' . $value_criteria . '</strong></span></div></div>';
}
$text .= '</div>';
$text .= '<div class="user_reviews_view_proscons"><div class="comm_text_from_review">' . get_comment_text() . '</div>';
if (isset($pros_review) && $pros_review != '') {
$text .= '<div class="user_reviews_view_pros"><span class="user_reviews_view_pc_title">' . __('+ PROS:', 'rehub_framework') . ' </span><span> ' . $pros_review . '</span></div>';
}
if (isset($cons_review) && $cons_review != '') {
$text .= '<div class="user_reviews_view_cons"><span class="user_reviews_view_pc_title">' . __('- CONS:', 'rehub_framework') . '</span><span> ' . $cons_review . '</span></div>';
}
$text .= '</div></div>';
}
echo $text;
}
示例4: get_search_form
</div>
<?php
if (rehub_option('rehub_header_style') == 'header_first') {
?>
<div class="search head_search"><?php
get_search_form();
?>
</div><?php
}
?>
<?php
if (rehub_option('rehub_header_style') != 'header_third') {
if (rehub_option('rehub_ads_top')) {
?>
<div class="mediad"><?php
echo do_shortcode(rehub_option('rehub_ads_top'));
?>
</div><?php
}
}
?>
</div>
<!-- /Logo section -->
<!-- Main Navigation -->
<div class="main-nav">
<?php
wp_nav_menu(array('container_class' => 'top_menu', 'container' => 'nav', 'theme_location' => 'primary-menu', 'fallback_cb' => 'add_menu_for_blank'));
?>
<div class="responsive_nav_wrap"></div>
</div>
<!-- /Main Navigation -->
示例5: the_content
?>
<?php
the_content();
?>
<?php
}
?>
</div>
<!-- /Main Side -->
</div>
</div>
<!-- /CONTENT -->
<!-- FOOTER -->
<?php
if ($footer_disable == '1') {
if (rehub_option('rehub_analytics')) {
echo rehub_option('rehub_analytics');
}
if (rehub_option('rehub_disable_totop') != '1') {
?>
<a href="#top_ankor" class="rehub_scroll" id="topcontrol"><i class="fa fa-chevron-up"></i></a><?php
}
wp_footer();
?>
</body>
</html>
<?php
} else {
get_footer();
}
示例6: extract
<?php
$module_cat = $module_formats = $module_fetch = '';
extract(shortcode_atts(array('module_cat' => '', 'module_formats' => '', 'module_fetch' => '6'), $atts));
if ($module_formats == 'all') {
$module_formats = '';
}
$module_exclude = rehub_option('rehub_exclude_posts');
if ($module_exclude == 1) {
$exclude_posts = rehub_exclude_feature_posts();
} else {
$exclude_posts = '';
}
if (!is_paged()) {
wp_enqueue_script('carouFredSel');
?>
<div class="def-carousel sec_style_carousel loading">
<section class="clearfix">
<ul class="gallery-pics clearfix">
<?php
$gal_post_block = new WP_Query(array('cat' => $module_cat, 'post_type' => 'post', 'showposts' => $module_fetch, 'post__not_in' => $exclude_posts, 'meta_key' => 'rehub_framework_post_type', 'meta_value' => $module_formats, 'ignore_sticky_posts' => 1));
if ($gal_post_block->have_posts()) {
while ($gal_post_block->have_posts()) {
$gal_post_block->the_post();
?>
<li>
<a href="<?php
the_permalink();
?>
" class="gal_post_image"><?php
rehub_formats_icons();
示例7: elseif
<?php
if ($branded_banner_url != '') {
?>
</a><?php
}
?>
</div>
<style>.top_theme { display: none } .content.landing_page{ margin-top: 0 !important}</style>
<?php
} elseif (rehub_option('rehub_branded_banner_image')) {
?>
<?php
$branded_banner_url = rehub_option('rehub_branded_banner_url');
?>
<?php
$branded_banner_image = rehub_option('rehub_branded_banner_image');
?>
<div id="branded_img">
<?php
if ($branded_banner_url != '') {
?>
<a href="<?php
echo $branded_banner_url;
?>
" target="_blank"><?php
}
?>
<img alt="" src="<?php
echo esc_url($branded_banner_image);
?>
">
示例8: set_content_end
function set_content_end($content)
{
global $post;
if (is_feed()) {
return $content;
}
$output = '';
ob_start();
wp_link_pages(array('before' => '<div class="page-link">' . __('Pages:', 'rehub_child'), 'after' => '</div>'));
$output .= ob_get_clean();
$offer_url_exist = get_post_meta($post->ID, 'rehub_offer_product_url', true);
if (!empty($offer_url_exist)) {
$offer_shortcode = get_post_meta($post->ID, 'rehub_offer_shortcode', true);
if (empty($offer_shortcode)) {
ob_start();
echo '<div class="lined_r_title">' . __('Where to buy', 'rehub_child') . '</div>';
rehub_quick_offer();
$output .= ob_get_clean();
}
} elseif (vp_metabox('rehub_post.rehub_framework_post_type') == 'review') {
if (vp_metabox('rehub_post.review_post.0.review_post_product.0.review_post_offer_shortcode') != '1' && vp_metabox('rehub_post.review_post.0.review_post_schema_type') == 'review_post_review_product') {
ob_start();
echo '<div class="lined_r_title">' . __('Where to buy', 'rehub_child') . '</div>';
rehub_get_offer();
$output .= ob_get_clean();
}
if (vp_metabox('rehub_post.review_post.0.review_aff_product.0.review_aff_offer_shortcode') != '1' && vp_metabox('rehub_post.review_post.0.review_post_schema_type') == 'review_aff_product') {
ob_start();
echo '<div class="lined_r_title">' . __('Where to buy', 'rehub_child') . '</div>';
rehub_get_aff_offer();
$output .= ob_get_clean();
}
if (vp_metabox('rehub_post.review_post.0.review_woo_product.0.review_woo_offer_shortcode') != '1' && vp_metabox('rehub_post.review_post.0.review_post_schema_type') == 'review_woo_product') {
$review_woo_link = vp_metabox('rehub_post.review_post.0.review_woo_product.0.review_woo_link');
ob_start();
echo '<div class="lined_r_title">' . __('Where to buy', 'rehub_child') . '</div>';
rehub_get_woo_offer($review_woo_link);
$output .= ob_get_clean();
}
if (vp_metabox('rehub_post.review_post.0.review_woo_list.0.review_woo_list_shortcode') != '1' && vp_metabox('rehub_post.review_post.0.review_post_schema_type') == 'review_woo_list') {
$review_woo_list_links = vp_metabox('rehub_post.review_post.0.review_woo_list.0.review_woo_list_links');
if (is_array($review_woo_list_links)) {
$review_woo_list_links = implode(',', $review_woo_list_links);
}
ob_start();
echo '<div class="lined_r_title">' . __('Where to buy', 'rehub_child') . '</div>';
rehub_get_woo_list($data_source = 'ids', $type = '', $cat = '', $tag = '', $ids = $review_woo_list_links);
$output .= ob_get_clean();
}
}
if (vp_metabox('rehub_post.rehub_framework_post_type') == 'review' && vp_metabox('rehub_post.review_post.0.review_post_product_shortcode') == '0') {
$overal_score = rehub_get_overall_score();
$postAverage = get_post_meta(get_the_ID(), 'post_user_average', true);
ob_start();
if (rehub_option('type_user_review') == 'full_review' && ($postAverage != '0' && $postAverage != '')) {
echo '<div class="lined_r_title">' . __('Review Score', 'rehub_child') . '</div>';
} elseif ($overal_score != '0' && $overal_score != '') {
echo '<div class="lined_r_title">' . __('Review Score', 'rehub_child') . '</div>';
}
rehub_get_review();
$output .= ob_get_clean();
}
return $content . $output;
}
示例9: rehub_option
html#ecwid_html body#ecwid_body div.ecwid-ContinueShoppingButton-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-ContinueShoppingButton-ie6-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-AddToBagButton-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-AddToBagButton-ie6-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-productBrowser-cart-checkoutButton-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-productBrowser-cart-checkoutButton-ie6-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-Checkout-placeOrderButton-up-hovering, html#ecwid_html body#ecwid_body div.ecwid-Checkout-placeOrderButton-ie6-up-hovering, html#ecwid_html body#ecwid_body button.ecwid-AccentedButton:hover { background-color: #111111 !important; background-position: left bottom !important }
<?php
if (rehub_option('rehub_review_color')) {
?>
.rate-line .filled, .rate_bar_wrap .review-top .overall-score, .rate-bar-bar, .top_rating_item .score.square_score, .rate_bar_wrap_two_reviews .user-review-criteria .rate-bar-bar{background-color: <?php
echo rehub_option('rehub_review_color');
?>
;}
.meter-wrapper .meter{border-color: <?php
echo rehub_option('rehub_review_color');
?>
;}
.userstar-rating span:before{color: <?php
echo rehub_option('rehub_review_color');
?>
;}
.rate_bar_wrap .review-top .overall-score span.overall-text{border: 1px solid <?php
echo rehub_option('rehub_review_color');
?>
;}
.rate_bar_wrap_two_reviews .score_val, .rate_bar_wrap_two_reviews .user-review-criteria .score_val{border-bottom: 3px solid <?php
echo rehub_option('rehub_review_color');
?>
}
<?php
}
?>
</style>
示例10: rehub_pagination
</div>
<?php
} else {
?>
<div class="pagination"><?php
rehub_pagination();
?>
</div>
<?php
}
?>
</div>
<!-- /Main Side -->
<?php
if (rehub_option('rehub_framework_category_layout') == 'two_column_with' || rehub_option('rehub_framework_category_layout') == 'blog_with' || rehub_option('rehub_framework_category_layout') == 'list_with') {
?>
<!-- Sidebar -->
<?php
get_sidebar();
?>
<!-- /Sidebar -->
<?php
}
?>
</div>
</div>
<!-- /CONTENT -->
<!-- FOOTER -->
<?php
get_footer();
示例11: rehub_pagination
</div>
<?php
} else {
?>
<div class="pagination"><?php
rehub_pagination();
?>
</div>
<?php
}
?>
</div>
<!-- /Main Side -->
<?php
if (rehub_option('rehub_framework_archive_layout') == 'two_column_with' || rehub_option('rehub_framework_archive_layout') == 'blog_with' || rehub_option('rehub_framework_archive_layout') == 'list_with') {
?>
<!-- Sidebar -->
<?php
get_sidebar();
?>
<!-- /Sidebar -->
<?php
}
?>
</div>
</div>
<!-- /CONTENT -->
<!-- FOOTER -->
<?php
get_footer();
示例12: vp_metabox
<?php
if (vp_metabox('rehub_framework_brand.rehub_branded_bg_url_single') && (is_single() || is_page())) {
?>
<?php
$branded_bg_url = vp_metabox('rehub_framework_brand.rehub_branded_bg_url_single');
?>
<a id="branded_bg" href="<?php
echo $branded_bg_url;
?>
" target="_blank" rel="nofollow"></a>
<?php
} elseif (rehub_option('rehub_branded_bg_url')) {
?>
<?php
$branded_bg_url = rehub_option('rehub_branded_bg_url');
?>
<a id="branded_bg" href="<?php
echo $branded_bg_url;
?>
" target="_blank" rel="nofollow"></a>
<?php
}
示例13: ajax_action_picker_home
function ajax_action_picker_home()
{
$nonce = $_POST['nonce'];
if (!wp_verify_nonce($nonce, 'ajax-nonce')) {
die('Nope!');
}
$data = $_POST;
$query_args = array('post_type' => 'post', 'post_status' => 'publish', 'posts_per_page' => 12, 'ignore_sticky_posts' => 1);
if ($data['sorttype'] == 'hot') {
$query_args['meta_key'] = 'post_hot_count';
$query_args['orderby'] = 'meta_value_num';
} elseif ($data['sorttype'] == 'popular') {
$query_args['meta_key'] = 'rehub_views';
$query_args['orderby'] = 'meta_value_num';
} elseif ($data['sorttype'] == 'bestprice') {
$query_args['meta_key'] = rehub_option('rehub_home_price');
$query_args['orderby'] = 'meta_value_num';
$query_args['order'] = 'ASC';
} elseif ($data['sorttype'] == 'mostprice') {
$query_args['meta_key'] = rehub_option('rehub_home_price');
$query_args['orderby'] = 'meta_value_num';
$query_args['order'] = 'DESC';
} elseif ($data['sorttype'] == 'random') {
$query_args['orderby'] = 'rand';
}
if (isset($data['offset']) && !empty($data['offset'])) {
$query_args['offset'] = $data['offset'];
}
$offset = isset($data['offset']) && !empty($data['offset']) ? $data['offset'] + 12 : 12;
$wp_query = new WP_Query($query_args);
$count = 0;
if ($wp_query->have_posts()) {
$response = '<div class="masonry_grid_fullwidth three-col-gridhub">';
while ($wp_query->have_posts()) {
$wp_query->the_post();
ob_start();
$count++;
include locate_template('inc/parts/query_type3.php');
$response .= ob_get_clean();
}
$response .= '</div><div class="clearfix"></div>';
$response .= '<div class="more_post onclick home_picker_next"><span data-sorttype="' . $data['sorttype'] . '" data-offset="' . $offset . '">' . __('Next posts', 'rehub_child') . '</span></div>';
} else {
$response = '<div><span class="no_more_posts">' . __('No more posts!', 'rehub_child') . '<span></div><div class="clearfix"></div>';
}
wp_reset_postdata();
echo $response;
exit;
}
示例14: wpsm_toptable_shortcode
//.........这里部分代码省略.........
}
?>
<figure>
<?php
if (!is_paged() && $first_column_rank) {
?>
<span class="rank_count"><?php
if ($i == '1') {
?>
<i class="fa fa-trophy"></i><?php
} else {
echo $i;
}
?>
</span><?php
}
?>
<?php
$link_on_thumb = $affiliate_link != '' ? rehub_create_affiliate_link() : get_the_permalink();
?>
<?php
$link_on_thumb_target = $affiliate_link != '' ? ' class="btn_offer_block"' : '';
?>
<a href="<?php
echo $link_on_thumb;
?>
" target="_blank"<?php
echo $link_on_thumb_target;
?>
>
<?php
$img = get_post_thumb();
$nothumb = get_template_directory_uri() . '/images/default/noimage_100_70.png';
if (rehub_option('aq_resize_crop') == '1') {
$params = array('width' => 100);
} else {
$params = array('width' => 100, 'height' => 100, 'crop' => true);
}
?>
<?php
if (!empty($img)) {
?>
<img src="<?php
echo bfi_thumb($img, $params);
?>
" alt="<?php
the_title_attribute();
?>
" />
<?php
} else {
?>
<img src="<?php
echo $nothumb;
?>
" alt="<?php
the_title_attribute();
?>
" />
<?php
}
?>
</a>
</figure>
</td>
示例15: _e
?>
<?php
_e('By', 'rehub_framework');
?>
<a class="admin" href="<?php
echo get_author_posts_url(get_the_author_meta('ID', $author_id));
?>
"><?php
echo get_the_author_meta('user_nicename', $author_id);
?>
</a>
<?php
}
?>
<?php
if (rehub_option('exclude_date_meta') == 0) {
?>
<?php
_e('on', 'rehub_framework');
?>
<span class="date"><?php
the_time('F j, Y');
?>
</span>
<?php
}
?>
</div>
<meta itemprop="datePublished" content="<?php
the_time('Y-m-d');