function smartline_css_layout() { // Get Theme Options from Database $theme_options = smartline_theme_options(); // Switch Sidebar to left if (isset($theme_options['layout']) and $theme_options['layout'] == 'left-sidebar') { echo '<style type="text/css"> @media only screen and (min-width: 60em) { #content { float: right; } #sidebar { margin-left: 0; margin-right: 70%; background: -moz-linear-gradient(left, #f3f3f3 0%, #e6e6e6 100%); /* FF3.6+ */ background: -webkit-gradient(linear, left top, right top, color-stop(0%,#f3f3f3), color-stop(100%,#e6e6e6)); /* Chrome,Safari4+ */ background: -webkit-linear-gradient(left, #f3f3f3 0%,#e6e6e6 100%); /* Chrome10+,Safari5.1+ */ background: -o-linear-gradient(left, #f3f3f3 0%,#e6e6e6 100%); /* Opera 11.10+ */ background: -ms-linear-gradient(left, #f3f3f3 0%,#e6e6e6 100%); /* IE10+ */ background: linear-gradient(to right, #f3f3f3 0%,#e6e6e6 100%); /* W3C */ } } @media only screen and (max-width: 70em) { #sidebar { margin-right: 67%; } } </style>'; } }
function smartline_fonts_url() { $fonts_url = ''; // Get Theme Options from Database $theme_options = smartline_theme_options(); // Only embed Google Fonts if not deactivated if ( ! ( isset($theme_options['deactivate_google_fonts']) and $theme_options['deactivate_google_fonts'] == true ) ) : // Set Default Fonts $font_families = array('Raleway:400,700', 'Bitter'); // Set Google Font Query Args $query_args = array( 'family' => urlencode( implode( '|', $font_families ) ), 'subset' => urlencode( 'latin,latin-ext' ), ); // Create Fonts URL $fonts_url = add_query_arg( $query_args, '//fonts.googleapis.com/css' ); endif; return apply_filters( 'smartline_google_fonts_url', $fonts_url ); }
function smartline_excerpt_more($more) { // Get Theme Options from Database $theme_options = smartline_theme_options(); // Return Excerpt Text if ( isset($theme_options['excerpt_text']) and $theme_options['excerpt_text'] == true ) : return ' [...]'; else : return ''; endif; }
function smartline_custom_jscript_slider() { // Get Theme Options from Database $theme_options = smartline_theme_options(); // Set Parameters array $params = array(); // Define Slider Animation if (isset($theme_options['slider_animation'])) { $params['animation'] = esc_js($theme_options['slider_animation']); } // Passing Parameters to Javascript wp_localize_script('smartline-lite-jquery-frontpage_slider', 'smartline_slider_params', $params); }
?> /js/html5shiv.min.js" type="text/javascript"></script> <![endif]--> <?php wp_head(); ?> </head> <body <?php body_class(); ?> > <?php // Get Theme Options from Database $theme_options = smartline_theme_options(); ?> <div id="wrapper" class="hfeed"> <div id="header-wrap"> <?php // Display Top Navigation if (has_nav_menu('secondary')) { ?> <nav id="topnav" class="clearfix" role="navigation"> <?php wp_nav_menu(array('theme_location' => 'secondary', 'container' => false, 'menu_id' => 'topnav-menu', 'fallback_cb' => '', 'depth' => 1)); ?>
function smartline_display_postinfo() { // Get Theme Options from Database $theme_options = smartline_theme_options(); // Display Comments if ( comments_open() ) : ?> <span class="meta-comments"> <?php comments_popup_link( esc_html__( 'Leave a comment', 'smartline-lite' ), esc_html__( 'One comment', 'smartline-lite' ), esc_html__( '% comments', 'smartline-lite' ) ); ?> </span> <?php endif; // Display Tags unless user has deactivated it via settings if ( isset($theme_options['meta_tags']) and $theme_options['meta_tags'] == true ) : $tag_list = get_the_tag_list('', ', '); if ( $tag_list ) : ?> <span class="meta-tags"> <?php echo $tag_list; ?> </span> <?php endif; endif; }
function smartline_display_thumbnail_single() { // Get Theme Options from Database $theme_options = smartline_theme_options(); // Display Post Thumbnail if activated if (isset($theme_options['post_thumbnails_single']) and $theme_options['post_thumbnails_single'] == true) { the_post_thumbnail('featured_image', array('class' => 'alignleft')); } }