Example #1
0
    ?>
	<nav role="navigation" class="navigation site-navigation secondary-navigation">
		<?php 
    wp_nav_menu(array('theme_location' => 'secondary'));
    ?>
	</nav>
	<?php 
}
?>

	<?php 
if (function_exists('fw_ext_sidebars_get_current_position')) {
    ?>
		<div id="primary-sidebar" class="primary-sidebar widget-area" role="complementary">
			<?php 
    $current_position = fw_ext_sidebars_get_current_position();
    ?>
			<?php 
    if ($current_position !== 'full') {
        ?>
				<?php 
        if ($current_position === 'left' or $current_position === 'left_right') {
            ?>
					<?php 
            echo fw_ext_sidebars_show('blue');
            ?>
				<?php 
        }
        ?>
			<?php 
    }
Example #2
0
                }
            }
            $text = sprintf(__('You answered correctly %s questions from %s', 'fw'), $correct, count($response['questions']));
        }
    }
    ?>
				<article id="post-<?php 
    the_ID();
    ?>
" <?php 
    post_class('', $lesson->ID);
    ?>
>
					<div class="post-thumbnail">
						<?php 
    if (function_exists('fw_ext_sidebars_get_current_position') && in_array(fw_ext_sidebars_get_current_position(), array('full', 'left')) || is_page_template('page-templates/full-width.php')) {
        echo get_the_post_thumbnail($lesson->ID, 'fw-theme-full-width');
    } else {
        echo get_the_post_thumbnail($lesson->ID);
    }
    ?>
					</div>

					<header class="entry-header">
						<h1 class="entry-title">
							<a href="<?php 
    the_permalink();
    ?>
"><?php 
    echo $lesson->post_title;
    ?>
Example #3
0
<?php

/**
 * The Sidebar containing the main widget area
 */
$current_position = function_exists('fw_ext_sidebars_get_current_position') ? fw_ext_sidebars_get_current_position() : 'right';
if ($current_position !== 'full' && $current_position !== null) {
    ?>
    <aside>
        <?php 
    if ($current_position === 'left' or $current_position === 'right') {
        ?>
            <?php 
        if (function_exists('fw_ext_sidebars_show')) {
            echo fw_ext_sidebars_show('blue');
        } else {
            dynamic_sidebar('sidebar-1');
        }
        ?>
        <?php 
    }
    ?>
    </aside>
<?php 
}
Example #4
0
/**
 * Extend the default WordPress body classes.
 *
 * Adds body classes to denote:
 * 1. Single or multiple authors.
 * 2. Presence of header image.
 * 3. Index views.
 * 4. Full-width content layout.
 * 5. Presence of footer widgets.
 * 6. Single views.
 * 7. Featured content layout.
 *
 * @param array $classes A list of existing body class values.
 *
 * @return array The filtered body class list.
 * @internal
 */
function _filter_theme_body_classes($classes)
{
    if (is_multi_author()) {
        $classes[] = 'group-blog';
    }
    if (get_header_image()) {
        $classes[] = 'header-image';
    } else {
        $classes[] = 'masthead-fixed';
    }
    if (is_archive() || is_search() || is_home()) {
        $classes[] = 'list-view';
    }
    if (function_exists('fw_ext_sidebars_get_current_position')) {
        $current_position = fw_ext_sidebars_get_current_position();
        if (in_array($current_position, array('full', 'left')) || empty($current_position) || is_page_template('page-templates/full-width.php') || is_page_template('page-templates/contributors.php') || is_attachment()) {
            $classes[] = 'full-width';
        }
    } else {
        $classes[] = 'full-width';
    }
    if (is_active_sidebar('sidebar-1')) {
        $classes[] = 'footer-widgets';
    }
    if (is_singular() && !is_front_page()) {
        $classes[] = 'singular';
    }
    if (is_front_page() && 'slider' == get_theme_mod('featured_content_layout')) {
        $classes[] = 'slider';
    } elseif (is_front_page()) {
        $classes[] = 'grid';
    }
    return $classes;
}
Example #5
0
/**
 * Display an optional post thumbnail.
 *
 * Wraps the post thumbnail in an anchor element on index
 * views, or a div element when on single views.
 */
function fw_theme_post_thumbnail()
{
    if (post_password_required() || is_attachment() || !has_post_thumbnail()) {
        return;
    }
    if (is_singular()) {
        ?>

			<div class="post-thumbnail">
				<?php 
        if (in_array(fw_ext_sidebars_get_current_position(), array('full', 'left')) || is_page_template('page-templates/full-width.php')) {
            the_post_thumbnail('fw-theme-full-width');
        } else {
            the_post_thumbnail();
        }
        ?>
			</div>

		<?php 
    } else {
        ?>

			<a class="post-thumbnail" href="<?php 
        the_permalink();
        ?>
">
				<?php 
        if (in_array(fw_ext_sidebars_get_current_position(), array('full', 'left')) || is_page_template('page-templates/full-width.php')) {
            the_post_thumbnail('fw-theme-full-width');
        } else {
            the_post_thumbnail();
        }
        ?>
			</a>

		<?php 
    }
    // End is_singular()
}
Example #6
0
get_header();
?>

<?php 
$header_image = defined('FW') ? fw_get_db_settings_option('header_404_image') : '';
$header_color = defined('FW') ? fw_get_db_settings_option('header_404_color') : '';
$header_pattern = defined('FW') ? fw_get_db_settings_option('header_404_pattern') : '';
$header_title = defined('FW') && fw_get_db_settings_option('header_404_title') ? esc_attr(fw_get_db_settings_option('header_404_title')) : __('404 Page', 'fw');
//show header image
fw_show_header($header_image, $header_color, $header_pattern, $header_title);
//get blog view type
$blog_view = fw_get_db_settings_option('blog_view');
?>

<?php 
$sidebar_position = function_exists('fw_ext_sidebars_get_current_position') ? fw_ext_sidebars_get_current_position() : 'full';
?>
    <section id="content" <?php 
echo $blog_view == 'blog2' ? 'class="news-b"' : '';
?>
>

        <header class="heading-a">
            <h3><span class="small"><?php 
echo $header_title;
?>
</span>
                <?php 
echo defined('FW') ? fw_theme_translate(fw_get_db_settings_option('404-description')) : '';
?>
            </h3>