<div class="group pad"> <?php echo hu_site_title(); ?> <?php if (hu_is_checked('site-description')) { ?> <p class="site-description"><?php bloginfo('description'); ?> </p><?php } ?> <?php if (hu_is_checked('header-ads')) { ?> <div id="header-widgets"> <?php hu_print_widgets_in_location('header-ads'); ?> </div><!--/#header-ads--> <?php } ?> </div> <?php } else { ?>
<?php } ?> <div class="search-again"> <?php get_search_form(); ?> </div> </div> <?php if (have_posts()) { ?> <?php if (hu_is_checked('blog-standard')) { ?> <?php while (have_posts()) { the_post(); ?> <?php get_template_part('content-standard'); ?> <?php } ?> <?php } else { ?> <div class="post-list group">
function hu_pre_get_posts($query) { // Is the featured post option enabled ? if (!hu_is_checked('featured-posts-enabled')) { return; } // Are we on main query ? if (!$query->is_main_query()) { return; } // Are we on the blog page ? if (!$query->is_home()) { return; } if ($query->is_home()) { // Featured posts enabled if (hu_get_option('featured-posts-count') != '0' && false !== (bool) hu_get_option('featured-posts-count')) { // Get featured post ids $featured_post_ids = hu_get_featured_post_ids(); // Exclude posts if ($featured_post_ids && !hu_is_checked('featured-posts-include')) { $query->set('post__not_in', $featured_post_ids); } } } }
echo date('Y'); ?> . <?php _e('All Rights Reserved.', 'hueman'); ?> </p> <?php } ?> </div><!--/#copyright--> <?php if (hu_is_checked('credit') || hu_is_customizing()) { ?> <div id="credit" style="<?php echo !hu_is_checked('credit') ? 'display:none' : ''; ?> "> <p><?php _e('Powered by', 'hueman'); ?> <a href="http://wordpress.org" target="_blank">WordPress</a>. <?php _e('Theme by', 'hueman'); ?> <a href="http://presscustomizr.com">Press Customizr</a>.</p> </div><!--/#credit--> <?php } ?> </div>
echo '<span class="thumb-icon"><i class="fa fa-play"></i></span>'; } ?> <?php if (has_post_format('audio') && !is_sticky()) { echo '<span class="thumb-icon"><i class="fa fa-volume-up"></i></span>'; } ?> <?php if (is_sticky()) { echo '<span class="thumb-icon"><i class="fa fa-star"></i></span>'; } ?> </a> <?php if (comments_open() && hu_is_checked('comment-count')) { ?> <a class="post-comments" href="<?php comments_link(); ?> "><span><i class="fa fa-comments-o"></i><?php comments_number('0', '1', '%'); ?> </span></a> <?php } ?> </div><!--/.post-thumbnail--> <div class="post-content">
<?php get_template_part('parts/page-image'); ?> <div class="entry themeform"> <?php the_content(); ?> <div class="clear"></div> </div><!--/.entry--> </article> <?php if (hu_is_checked('page-comments')) { comments_template('/comments.php', true); } ?> <?php } ?> </div><!--/.pad--> </section><!--/.content--> <?php get_sidebar(); ?>
/* Print the post author. Compatible with Google Structured data. Must be used in the WordPress loop * @php return html string /* ------------------------------------ */ $published_date = get_the_date(get_option('date_format')); ?> <p class="post-byline"><?php _e('by', 'hueman'); ?> <span class="vcard author"> <span class="fn"><?php the_author_posts_link(); ?> </span> </span> · <?php if (hu_is_checked('structured-data')) { ?> <?php if (get_the_modified_date() != get_the_date() || get_the_modified_time() != get_the_time()) { ?> <?php _e('Published', 'hueman'); ?> <time class="published" datetime="<?php echo $published_date; ?> "><?php echo $published_date; ?> </time> · <?php
<?php get_header(); ?> <section class="content"> <?php get_template_part('parts/page-title'); ?> <div class="pad group"> <?php if (hu_is_checked('featured-posts-enabled')) { get_template_part('parts/featured'); } ?> <?php if (have_posts()) { ?> <?php if (hu_get_option('blog-standard') == 'on') { ?> <?php while (have_posts()) { the_post(); ?> <?php
<?php } elseif (is_year()) { ?> <h1><i class="fa fa-calendar"></i><?php _e('Yearly Archive:', 'hueman'); ?> <span><?php echo get_the_time('Y'); ?> </span></h1> <?php } else { ?> <?php if (!is_home() && !hu_is_checked('blog-heading-enabled')) { ?> <h2><?php the_title(); ?> </h2> <?php } ?> <?php } ?> </div><!--/.page-title-->
function hu_dynamic_css() { if (!hu_is_checked('dynamic-styles')) { return; } // rgb values $color_1 = hu_get_option('color-1'); $color_1_rgb = hu_hex2rgb($color_1); // start output $styles = '<style type="text/css">' . "\n"; $styles .= '/* Dynamic CSS: For no styles in head, copy and put the css below in your child theme\'s style.css, disable dynamic styles */' . "\n"; // google fonts if (hu_get_option('font') == 'titillium-web-ext') { $styles .= 'body { font-family: "Titillium Web", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'droid-serif') { $styles .= 'body { font-family: "Droid Serif", serif; }' . "\n"; } if (hu_get_option('font') == 'source-sans-pro') { $styles .= 'body { font-family: "Source Sans Pro", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'lato') { $styles .= 'body { font-family: "Lato", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'raleway') { $styles .= 'body { font-family: "Raleway", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'ubuntu' || hu_get_option('font') == 'ubuntu-cyr') { $styles .= 'body { font-family: "Ubuntu", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'roboto-condensed' || hu_get_option('font') == 'roboto-condensed-cyr') { $styles .= 'body { font-family: "Roboto Condensed", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'roboto-slab' || hu_get_option('font') == 'roboto-slab-cyr') { $styles .= 'body { font-family: "Roboto Slab", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'playfair-display' || hu_get_option('font') == 'playfair-display-cyr') { $styles .= 'body { font-family: "Playfair Display", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'open-sans' || hu_get_option('font') == 'open-sans-cyr') { $styles .= 'body { font-family: "Open Sans", Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'pt-serif' || hu_get_option('font') == 'pt-serif-cyr') { $styles .= 'body { font-family: "PT Serif", serif; }' . "\n"; } if (hu_get_option('font') == 'arial') { $styles .= 'body { font-family: Arial, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'georgia') { $styles .= 'body { font-family: Georgia, serif; }' . "\n"; } if (hu_get_option('font') == 'verdana') { $styles .= 'body { font-family: Verdana, sans-serif; }' . "\n"; } if (hu_get_option('font') == 'tahoma') { $styles .= 'body { font-family: Tahoma, sans-serif; }' . "\n"; } // container width if (hu_get_option('container-width') != '1380') { if (hu_is_checked('boxed')) { $styles .= '.boxed #wrapper, .container-inner { max-width: ' . hu_get_option('container-width') . 'px; }' . "\n"; } else { $styles .= '.container-inner { max-width: ' . hu_get_option('container-width') . 'px; }' . "\n"; } } // sidebar padding if (hu_get_option('sidebar-padding') != '30') { $styles .= '.sidebar .widget { padding-left: ' . hu_get_option('sidebar-padding') . 'px; padding-right: ' . hu_get_option('sidebar-padding') . 'px; padding-top: ' . hu_get_option('sidebar-padding') . 'px; }' . "\n"; } // primary color if (hu_get_option('color-1') != '#3b8dbd') { $styles .= ' ::selection { background-color: ' . hu_get_option('color-1') . '; } ::-moz-selection { background-color: ' . hu_get_option('color-1') . '; } a, .themeform label .required, #flexslider-featured .flex-direction-nav .flex-next:hover, #flexslider-featured .flex-direction-nav .flex-prev:hover, .post-hover:hover .post-title a, .post-title a:hover, .s1 .post-nav li a:hover i, .content .post-nav li a:hover i, .post-related a:hover, .s1 .widget_rss ul li a, #footer .widget_rss ul li a, .s1 .widget_calendar a, #footer .widget_calendar a, .s1 .alx-tab .tab-item-category a, .s1 .alx-posts .post-item-category a, .s1 .alx-tab li:hover .tab-item-title a, .s1 .alx-tab li:hover .tab-item-comment a, .s1 .alx-posts li:hover .post-item-title a, #footer .alx-tab .tab-item-category a, #footer .alx-posts .post-item-category a, #footer .alx-tab li:hover .tab-item-title a, #footer .alx-tab li:hover .tab-item-comment a, #footer .alx-posts li:hover .post-item-title a, .comment-tabs li.active a, .comment-awaiting-moderation, .child-menu a:hover, .child-menu .current_page_item > a, .wp-pagenavi a { color: ' . hu_get_option('color-1') . '; } .themeform input[type="submit"], .themeform button[type="submit"], .s1 .sidebar-top, .s1 .sidebar-toggle, #flexslider-featured .flex-control-nav li a.flex-active, .post-tags a:hover, .s1 .widget_calendar caption, #footer .widget_calendar caption, .author-bio .bio-avatar:after, .commentlist li.bypostauthor > .comment-body:after, .commentlist li.comment-author-admin > .comment-body:after { background-color: ' . hu_get_option('color-1') . '; } .post-format .format-container { border-color: ' . hu_get_option('color-1') . '; } .s1 .alx-tabs-nav li.active a, #footer .alx-tabs-nav li.active a, .comment-tabs li.active a, .wp-pagenavi a:hover, .wp-pagenavi a:active, .wp-pagenavi span.current { border-bottom-color: ' . hu_get_option('color-1') . '!important; } ' . "\n"; } // secondary color if (hu_get_option('color-2') != '#82b965') { $styles .= ' .s2 .post-nav li a:hover i, .s2 .widget_rss ul li a, .s2 .widget_calendar a, .s2 .alx-tab .tab-item-category a, .s2 .alx-posts .post-item-category a, .s2 .alx-tab li:hover .tab-item-title a, .s2 .alx-tab li:hover .tab-item-comment a, .s2 .alx-posts li:hover .post-item-title a { color: ' . hu_get_option('color-2') . '; } .s2 .sidebar-top, .s2 .sidebar-toggle, .post-comments, .jp-play-bar, .jp-volume-bar-value, .s2 .widget_calendar caption { background-color: ' . hu_get_option('color-2') . '; } .s2 .alx-tabs-nav li.active a { border-bottom-color: ' . hu_get_option('color-2') . '; } .post-comments span:before { border-right-color: ' . hu_get_option('color-2') . '; } ' . "\n"; } // topbar color if (hu_get_option('color-topbar') != '#26272b') { $styles .= ' .search-expand, #nav-topbar.nav-container { background-color: ' . hu_get_option('color-topbar') . '; } @media only screen and (min-width: 720px) { #nav-topbar .nav ul { background-color: ' . hu_get_option('color-topbar') . '; } } ' . "\n"; } // header color if (hu_get_option('color-header') != '#33363b') { $styles .= ' #header { background-color: ' . hu_get_option('color-header') . '; } @media only screen and (min-width: 720px) { #nav-header .nav ul { background-color: ' . hu_get_option('color-header') . '; } } ' . "\n"; } // header menu color if (hu_get_option('color-header-menu') != '') { $styles .= ' #nav-header.nav-container { background-color: ' . hu_get_option('color-header-menu') . '; } @media only screen and (min-width: 720px) { #nav-header .nav ul { background-color: ' . hu_get_option('color-header-menu') . '; } } ' . "\n"; } // footer color if (hu_get_option('color-footer') != '#33363b') { $styles .= '#footer-bottom { background-color: ' . hu_get_option('color-footer') . '; }' . "\n"; } // header logo max-height if (hu_get_option('logo-max-height') != '60') { $styles .= '.site-title a img { max-height: ' . hu_get_option('logo-max-height') . 'px; }' . "\n"; } // image border radius if (hu_get_option('image-border-radius') != '0') { $styles .= 'img { -webkit-border-radius: ' . hu_get_option('image-border-radius') . 'px; border-radius: ' . hu_get_option('image-border-radius') . 'px; }' . "\n"; } // // body background (old) // if ( hu_get_option('body-background') != '#eaeaea' ) { // $styles .= 'body { background-color: '.hu_get_option('body-background').'; }'."\n"; // } // body background (@fromfull) => keep on wp.org $body_bg = hu_get_option('body-background'); if (!empty($body_bg)) { //for users of wp.org version prior to 3.0+, this option is an hex color string. if (is_string($body_bg)) { $styles .= 'body { background-color: ' . $body_bg . '; }' . "\n"; } elseif (is_array($body_bg) && isset($body_bg['background-color'])) { $styles .= 'body { background-color: ' . $body_bg['background-color'] . '; }' . "\n"; } // elseif ( is_array($body_bg) ) { // $body_bg = wp_parse_args( // $body_bg, // array( // 'background-color' => "#eaeaea", // 'background-image' => false, // 'background-position' => '', // 'background-attachment' => '', // 'background-repeat' => '', // 'backgrount-size' => '' // ) // ); // $body_color = $body_bg['background-color']; // $body_image = $body_bg['background-image']; // $body_position = $body_bg['background-position']; // $body_attachment = $body_bg['background-attachment']; // $body_repeat = $body_bg['background-repeat']; // $body_size = $body_bg['background-size']; // if ( false !== $body_image && $body_size == "" ) { // $styles .= 'body { background: '.$body_color.' url('.$body_image.') '.$body_attachment.' '.$body_position.' '.$body_repeat.'; }'."\n"; // } elseif ( false !== $body_image && $body_size != "" ) { // $styles .= 'body { background: '.$body_color.' url('.$body_image.') '.$body_attachment.' '.$body_position.' '.$body_repeat.'; background-size: '.$body_size.'; }'."\n"; // } elseif ( '' != $body_color ) { // $styles .= 'body { background-color: '.$body_color.'; }'."\n"; // } else { // $styles .= ''; // } // } } $styles .= '</style>' . "\n"; // end output echo $styles; }
$layout = hu_layout_class(); if ($layout != 'col-1c') { ?> <div class="sidebar s1"> <a class="sidebar-toggle" title="<?php _e('Expand Sidebar', 'hueman'); ?> "><i class="fa icon-sidebar-toggle"></i></a> <div class="sidebar-content"> <?php if (hu_is_checked('sidebar-top')) { ?> <div class="sidebar-top group"> <p><?php echo hu_has_social_links() ? __('Follow:', 'hueman') : ' '; ?> </p> <?php hu_print_social_links(); ?> </div> <?php } ?> <?php
<h2 class="post-title entry-title"> <a href="<?php the_permalink(); ?> " rel="bookmark" title="<?php the_title(); ?> "><?php the_title(); ?> </a> </h2><!--/.post-title--> <?php if (!hu_is_checked('featured-posts-full-content')) { ?> <div class="entry excerpt entry-summary"> <?php if (hu_get_option('excerpt-length') != '0') { the_excerpt(); } ?> </div><!--/.entry--> <?php } else { ?> <div class="entry excerpt"> <?php the_content(); ?>
/** * Добавление сайдбара */ function arreat_register_sidebars() { if (hu_is_checked('subpost-ads')) { register_sidebar(['name' => 'Виджеты под записью', 'id' => 'subpost-ads', 'before_widget' => '<div id="%1$s" class="widget %2$s">', 'after_widget' => '</div>', 'before_title' => '<h3>', 'after_title' => '</h3>']); } }
} ?> <?php if (hu_is_checked('subpost-ads')) { get_template_part('inc/post-ads'); } ?> <?php if ('1' != hu_get_option('related-posts')) { get_template_part('parts/related-posts'); } ?> <?php if (hu_is_checked('post-comments')) { comments_template('/comments.php', true); } ?> </div><!--/.pad--> </section><!--/.content--> <?php get_sidebar(); ?> <?php get_footer();
clearInterval(checkforloaded); $('#flexslider-featured').flexslider({ animation: "slide", useCSS: false, // Fix iPad flickering issue directionNav: true, controlNav: true, pauseOnHover: true, animationSpeed: 400, smoothHeight: true, touch: <?php echo apply_filters('hu_flexslider_touch_support', true); ?> , slideshow: <?php echo hu_is_checked('featured-slideshow') ? 'true' : 'false'; ?> , slideshowSpeed: <?php echo hu_get_option('featured-slideshow-speed', 5000); ?> , }); } }, 20); }); </script> <div class="featured flexslider" id="flexslider-featured"> <ul class="slides">
function hu_add_help_button() { if (!current_user_can('edit_theme_options') || !hu_is_checked('help-button') || !hu_is_checked('about-page')) { return; } global $wp_admin_bar; $wp_admin_bar->add_menu(array('parent' => 'top-secondary', 'id' => 'tc-hueman-help', 'title' => __('Help', 'hueman'), 'href' => admin_url('themes.php?page=welcome.php&help=true'), 'meta' => array('title' => __('Need help with the Hueman theme ? Click here!', 'hueman')))); }