<?php /* T-MMM-emplate Name: Horizontal Portfolio */ gp_add_html_class('horizontal-page'); get_header(); ?> <div id="main" class="site site-with-sidebar"> <div id="content" class="site-content"> <div class="portfolio-list horizontal-content"><?php if (is_page()) { /** * We are on index page. * Let's modify main loop to gp_portfolio post type. * * If is_page() is false, then we are on taxonomy-gp-project-type.php * template, so our loop is already correct. */ gp_query_portfolio(); } if (have_posts()) { while (have_posts()) { the_post(); $project = new PortfolioProject(get_the_ID()); $featured = $project->get_featured_media(); if (!$featured) { continue; } // We have no media on this project, nothing to show. $attr['class'] = 'horizontal-item project';
<?php /* T-MMM-emplate Name: Full Page Slider */ gp_add_html_class('horizontal-page no-scroll'); if (have_posts()) { the_post(); $slides = gp_slider_get_published_slides($post->ID); $slides = apply_filters('gp_before_slider', $slides); $options = gp_slider_get_options($post->ID); $slider_attr = array(); if ($options['slideshow']) { $slider_attr['data-slideshow'] = '1'; $slider_attr['data-duration'] = $options['slideshow_interval']; } if (!is_front_page() && $slides && $slides[0]) { global $gp_theme; $data = gp_slider_get_slide_data($slides[0]->ID); $gp_theme->set_image($data['image']); $gp_theme->set_description($data['description']); } get_header(); if ($slides) { ?> <div id="main" class="site"> <a href="#" class="slider-arrow-left"><?php _e('Previous', 'gp'); ?>
<?php /** * T-MMM-emplate Name: Horizontal Blog * * @package gp * @since gp 1.2 */ gp_add_html_class('horizontal-page horizontal-posts'); get_header(); if (is_page()) { $paged = get_query_var('paged') ? get_query_var('paged') : 1; query_posts('post_type=post&paged=' . $paged); } ?> <div id="main" class="site site-with-sidebar"> <div id="content" class="site-content"><?php if (have_posts()) { ?> <div class="horizontal-content"><?php while (have_posts()) { the_post(); /** * Include the Post-Format-specific template for the content. */ ?> <div class="horizontal-item"> <?php get_template_part('content', get_post_format()); ?>
<?php /* T-MMM-emplate Name: Grid Portfolio */ gp_add_html_class('horizontal-page layout-portfolio-grid'); get_header(); if (is_page()) { gp_query_portfolio(); } if (have_posts()) { $grid_portfolio = new GridPortfolio(get_the_ID()); ?> <div id="main" class="site"> <div class="portfolio-grid" data-columns="<?php echo $grid_portfolio->get_grid_column_count(); ?> " data-rows="<?php echo $grid_portfolio->get_grid_row_count(); ?> "><?php while (have_posts()) { the_post(); $project = new PortfolioProject(get_the_ID()); $featured = $project->get_featured_media(); if (!$featured) { continue; } // We have no media on this project, nothing to show. if ($featured->is_image()) {
<?php /** * T-MMM-emplate Name: Vertical Blog * * @package gp * @since gp 1.2 */ gp_add_html_class('vertical-blog'); // Use increased excerpt length add_filter('excerpt_length', 'gp_increased_excerpt_lenght', 1002); get_header(); if (is_page()) { $paged = get_query_var('paged') ? get_query_var('paged') : 1; query_posts('post_type=post&paged=' . $paged); } ?> <div id="main" class="site site-with-sidebar"> <div id="content" class="site-content"><?php if (have_posts()) { while (have_posts()) { the_post(); /** * Include the Post-Format-specific template for the content. */ get_template_part('content', get_post_format()); } if ($wp_query->max_num_pages > 1) { gp_content_paging(); } } else {