-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathpage-portfolio-4col.php
77 lines (57 loc) · 2.22 KB
/
page-portfolio-4col.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<?php
/*
Template Name: Portfolio 4 columns
*/
?>
<?php get_header(); ?>
<div class="global_content_wrapper">
<div class="container_12">
<div class="grid_12">
<h1 class="entry-title"><?php the_title(); ?></h1>
<div class="content-area portfolio_section">
<div class="content_wrapper">
<?php
$temp = $wp_query;
$wp_query= null;
//$paged = (get_query_var('paged')) ? get_query_var('paged') : 1;
$post_counter = 0;
$wp_query = new WP_Query(array(
'post_type' => 'portfolio',
'posts_per_page' => 8,
'orderby'=> 'menu_order',
'paged'=>$paged
));
//$wp_query->query('posts_per_page=5'.'&paged='.$paged);
while ($wp_query->have_posts()) : $wp_query->the_post();
$post_counter++;
$related_thumb = wp_get_attachment_image_src( get_post_thumbnail_id(get_the_ID()), 'full' );
?>
<div class="portfolio_4_col_item_wrapper">
<div class="portfolio_item">
<div class="portfolio_item_img_container"><a href="<?php echo get_permalink(get_the_ID()); ?>"><img src="<?php echo $related_thumb[0]; ?>" alt="" /></a></div>
<a href="<?php echo get_permalink(get_the_ID()); ?>"><h3><?php the_title(); ?></h3></a>
<div class="portfolio_sep"></div>
<div class="portfolio_item_cat">
<?php
echo strip_tags (
get_the_term_list( get_the_ID(), 'portfolio_filter', "",", " )
);
?>
</div>
</div>
</div>
<?php endwhile; // end of the loop. ?>
<?php
if (function_exists("emm_paginate")) {
emm_paginate();
}
?>
<?php $wp_query = null; $wp_query = $temp;?>
</div><!-- #content .site-content -->
</div><!-- #primary .content-area -->
<?php theretailer_content_nav( 'nav-below' ); ?>
</div>
</div>
</div>
<?php get_template_part("dark_footer"); ?>
<?php get_footer(); ?>