85 lines
3.0 KiB
HTML
85 lines
3.0 KiB
HTML
title = "Habarlar"
|
|
url = "/habarlar"
|
|
layout = "master"
|
|
is_hidden = 0
|
|
|
|
[blogPosts]
|
|
pageNumber = "{{ :page }}"
|
|
postsPerPage = 10
|
|
noPostsMessage = "No posts found"
|
|
sortOrder = "published_at desc"
|
|
categoryPage = 404
|
|
postPage = "habar"
|
|
exceptPost = "{{ :id }}"
|
|
==
|
|
<div class="page-title-area page-title-img-two">
|
|
<div class="container">
|
|
<div class="page-title-item">
|
|
<h2>{{this.page.title}}</h2>
|
|
<ul>
|
|
<li>
|
|
<a href="/">Home</a>
|
|
</li>
|
|
<li>
|
|
<i class='bx bx-chevron-right'></i>
|
|
</li>
|
|
<li>{{this.page.title}}</li>
|
|
</ul>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
|
|
{% set posts = blogPosts.posts %}
|
|
|
|
<section class="blog-area ptb-100">
|
|
<div class="container">
|
|
<div class="section-title">
|
|
<h2>Habarlar</h2>
|
|
<!-- <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do tempor incididunt ut labore et dolore
|
|
magna aliqua.</p> -->
|
|
</div>
|
|
<div class="row">
|
|
|
|
{% for post in posts %}
|
|
<div class="col-sm-6 col-lg-4">
|
|
<div class="blog-item">
|
|
<div class="blog-top">
|
|
<a href="{{ post.url }}">
|
|
<img src="{{ post.featured_images[0].thumb(467,300,{'mode':'crop'}) }}" alt="Blog">
|
|
</a>
|
|
<span>{{ post.published_at|date('d.m.Y') }}</span>
|
|
</div>
|
|
<div class="blog-bottom">
|
|
<h3>
|
|
<a href="{{ post.url }}">{{ post.title }}</a>
|
|
</h3>
|
|
<p>{{ post.excerpt }}</p>
|
|
<a class="cmn-btn" href="{{ post.url }}">Read More</a>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endfor %}
|
|
|
|
</div>
|
|
<div class="row">
|
|
|
|
{% if posts.lastPage > 1 %}
|
|
<ul class="pagination">
|
|
{% if posts.currentPage > 1 %}
|
|
<li><a href="{{ this.page.baseFileName|page({ (blogPosts.pageParam): (posts.currentPage-1) }) }}">← Prev</a></li>
|
|
{% endif %}
|
|
|
|
{% for page in 1..posts.lastPage %}
|
|
<li class="{{ posts.currentPage == page ? 'active' : null }}">
|
|
<a href="{{ this.page.baseFileName|page({ (blogPosts.pageParam): page }) }}">{{ page }}</a>
|
|
</li>
|
|
{% endfor %}
|
|
|
|
{% if posts.lastPage > posts.currentPage %}
|
|
<li><a href="{{ this.page.baseFileName|page({ (blogPosts.pageParam): (posts.currentPage+1) }) }}">Next →</a></li>
|
|
{% endif %}
|
|
</ul>
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
</section> |