-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcategory.php
87 lines (74 loc) · 2.37 KB
/
category.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
78
79
80
81
82
83
84
85
86
87
<?php get_header(); ?>
<div class="container">
<div class="page-breadcrumbs">
<?php
echo '<h1 class="section-title">' . single_cat_title( '', false ) . '</i></h1>';
// Get page breadcrumb
get_breadcrumbs();
if ( category_description() ){
echo '<p>' . category_description() . '</p>';
}
?>
</div>
<section class="section">
<div class="row">
<div class="col-sm-9">
<?php
if( have_posts() ){
echo '<div class="section listing-news">';
while( have_posts() ){
the_post();
echo '<div class="post">';
if( ! empty( get_the_post_thumbnail() ) ){
echo '<div class="entry-header">';
echo '<div class="entry-thumbnail">';
echo get_the_post_thumbnail( get_the_id(), $themePrefix . 'singleThumbnail', array(
'title' => get_the_title(),
'alt' => get_the_excerpt(),
'class' => 'img-responsive'
)
);
echo '</div>';
echo '</div>';
}
?>
<div class="post-content">
<div class="entry-meta">
<ul class="list-inline">
<?php
// Author
echo '<li class="posted-by">';
echo '<i class="fa fa-user"></i>';
echo 'por <a href="' . get_author_posts_url( get_the_author_id() ) . '" title="Veja mais publicações de ' . get_the_author() . '">';
echo get_the_author();
echo '</a>';
echo '</li>';
// Date
echo '<li class="publish-date">';
echo '<i class="fa fa-clock-o"></i>';
echo get_the_date( 'd M, Y' );
echo '</li>';
// Views
echo getVisitorCount( get_the_id() );
// Comments
echo getCommentsCount( get_the_id() );
?>
</ul>
</div>
<?php
echo '<h2 class="entry-title"><a href="' . get_permalink() . '">' . get_the_title() . '</a></h2>';
echo '<div class="entry-content"><p>' . get_the_excerpt() . '</p></div>';
echo '</div>';
echo '</div>';
}
echo '</div>';
}
get_numeric_pagination();
?>
</div>
<?php get_sidebar(); ?>
</div>
</section>
</div>
</div>
<?php get_footer(); ?>