Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php get_header();?>
- <?php get_sidebar(); ?>
- <?php
- $term=get_term_by('slug',get_query_var( 'term' ),get_query_var('taxonomy'));
- $pagevar='?page=';
- $paged=get_query_var('page')?get_query_var('page'):1;
- //Estas informacoes permitem mostrar posts no formato de qualquer template na pasta templates
- $grid_template='grid-3'; //procure por "block entry item grid-" no arquivo de template que quer usar
- $nome_tamanho = '333x333'; // nome tamanho criado pelo plugin ou por chamada add_image_size
- $qntposts = '-1'; // no. de posts para carregar
- ;?>
- <div id="right" class="t-portfolio">
- <div id="content">
- <div id="content-inner">
- <div id="content-pad">
- <div class="grid-4">
- <?php global $wp_query; $curauth = $wp_query->get_queried_object();?>
- <h2><?php echo $curauth->display_name; ?></h2>
- </div>
- <div class="clear"></div>
- <?php if ($term->description): ?>
- <section class="description">
- <p><?php echo $term->description; ?></p>
- </section>
- <?php endif; ?>
- <div id="masonry">
- <?php $my_query = new WP_Query('post_type=portfolio&portfolio_tags='. $term->slug.'&paged='.$paged.'&posts_per_page='.$qntposts);
- while ($my_query->have_posts()) : $my_query->the_post(); ?>
- <article class="block entry item <?php echo $grid_template; ?> clearfix prettyPhoto" id="item-<?php the_ID(); ?>">
- <div class="item-img">
- <a href="<?php $imageArray = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID),'' );$imageURL = $imageArray[0];echo $imageArray[0] ; ?>" title="<?php the_title(); ?>" rel="prettyPhoto[pp_gal]"><?php if(has_post_thumbnail()) { echo get_the_post_thumbnail($post_id,$nome_tamanho);} ?><span class="icon"></span></a>
- <a class="item-title" href="<?php $imageArray = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID),'' ); $imageURL = $imageArray[0];echo $imageArray[0] ; ?>" title="<?php the_title(); ?>" rel="prettyPhoto[pp_gal]"><span><?php the_title(); ?></span></a>
- </div>
- <ul class="entry-meta clearfix">
- <li class="time"><i class="icon"></i><?php the_time('d/m/Y'); ?></li>
- </ul>
- <ul class="entry-meta clearfix" style="margin:-30px 0 0 0">
- <?php /* LISTA CATEGORIAS*/ $cats_list = get_the_term_list( $post->ID, 'portfolio_category', '', ', ', '' );
- if ( $cats_list ): ?>
- <li class="category" style="margin:0 0 0px 0"><i class="icon"></i><?php echo $cats_list;?></li>
- <?php endif; ?>
- <!--<li class="like-count"><a id="like-<?php the_ID(); ?>" href="#" <?php bandit::liked_class(); ?>>
- <i class="icon"></i><?php bandit::post_liked_count(); ?></a>
- </li> -->
- <!--<li class="comment-count"><a href="<?php comments_link(); ?>"><i class="icon"></i> <?php comments_number('0','1','%'); ?> </a></li> -->
- </ul>
- <ul class="entry-meta clearfix" style="margin:-30px 0 0 0">
- <li class="author" style="float:left;font-weight:bold;margin:0 0 0 0;"><i class="icon"></i><a href="<?php echo get_author_posts_url( get_the_author_meta( 'ID' ) ); ?>" rel="author"><?php printf( __( '%s', 'creatic' ), get_the_author() ); ?></a></li>
- <?php /* LISTA TAGS*/ $tags_list = get_the_term_list( $post->ID, 'portfolio_category', '', ', ', '' );
- if ( $tags_list ): ?>
- <!--<li class="tags" style="clear:both;margin:10px 0 0 0;float:left;padding:0"><i class="icon"></i><?php echo $tags_list;?></li> -->
- <?php endif; ?>
- </ul>
- </article>
- <?php endwhile; ?>
- </div><!--end masonry-->
- <div class="clear"></div>
- </div><!--end content-pad-->
- <div class="clear"></div>
- <?php if ($wp_query->max_num_pages > 1 && 1==$paged && $qntposts !='-1' ) : ?>
- <nav class="entry-nav clearfix" style="margin: 0 0 0 -10px">
- <p><a id="entry-load-more-link" data-empty="No more items available." data-max="<?php echo $my_query->max_num_pages; ?>" data-src="<?php echo get_term_link($term).$pagevar; ?>" href="#"><?php bandit::lang('post_nav_ajax',__('Load More','creatic')); ?></a></p>
- </nav>
- <?php endif; ?>
- <?php if(bandit::get_option('footer_widgets_portfolio')) { get_template_part('footer-widgets'); } // footer-widgets.php ?>
- </div><!--end content-inner-->
- <div class="clear"></div>
- </div><!--end content-->
- </div><!--end right-->
- <?php get_footer(); ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement