1
+ {% extends 'base.html' %}
2
+ {% load static %}
3
+ {% load humanize %}
4
+ {% load hitcount_tags %}
5
+ {% block head_title %}Blog Category{% endblock %}
6
+ {% block content %}
7
+ < style >
8
+ body {
9
+ background : var (--black );
10
+ background-repeat : no-repeat;
11
+ background-size : cover;
12
+ background-color : var (--black );
13
+ color : var (--yello );
14
+ }
15
+ </ style >
16
+ < section class ="my-5 ">
17
+ < div class ="container ">
18
+ < h5 class ="fw-bold mb-4 text-center ">
19
+ Category
20
+ </ h5 >
21
+ </ div >
22
+ < div class ="container ">
23
+ < div class ="row justify-content-start align-items-center ">
24
+ {% for post in posts %}
25
+ < div class ="col-sm-6 ">
26
+ < div class ="card ">
27
+
28
+ < div class ="card-img ">
29
+ < img class ="bd-placeholder-img card-img-top " src ="{{post.image_url}} " alt ="{{post.title}} ">
30
+ </ div >
31
+
32
+ < div class ="card-body ">
33
+ < div class ="card-content ">
34
+ < div class ="d-sm-flex justify-content-start align-items-center " style ="margin-left: 0; padding-left: 0; ">
35
+ < div class ="blog-date row justify-content-center text-center align-items-center fw-bold p-2 ">
36
+ < strong class ="col-12 p-0 "> {{ post.date_published.date}}</ strong >
37
+ </ div >
38
+ < div class ="d-grid justify-content-start mx-2 " style ="width: 100%; ">
39
+
40
+ < div class ="h6 ">
41
+ {{post.title}}
42
+ </ div >
43
+ < ul class ="mx-0 d-flex justify-content-between align-items-center small fs-6 " style ="width: 100%; padding-left: 0; margin-left: 0; ">
44
+ < li > < i class ="fa fa-user "> </ i > {{post.author}}</ li >
45
+ < li > < i class ="fa fa-comment "> </ i > Comments</ li >
46
+ < li > < i class ="fa fa-eye "> </ i > {% get_hit_count for post %} Views</ li >
47
+ </ ul >
48
+ </ div >
49
+ </ div >
50
+ < p class ="fw-normal ">
51
+ {{post.body|truncatewords:20 |safe}}
52
+ </ p >
53
+ < a href ="{{post.get_absolute_url}} " class ="btn btn-danger col-sm-6 col-md-4 "> Read More</ a >
54
+ </ div >
55
+ </ div >
56
+ </ div >
57
+ </ div >
58
+ {% endfor %}
59
+ < div class ="col-sm-6 ">
60
+ < div class ="card ">
61
+
62
+ < div class ="card-img ">
63
+ < img class ="bd-placeholder-img card-img-top " src ="{% static 'img/2.jpeg' %} " alt ="">
64
+ </ div >
65
+
66
+ < div class ="card-body ">
67
+ < div class ="card-content ">
68
+ < div class ="d-sm-flex justify-content-start align-items-center " style ="margin-left: 0; padding-left: 0; ">
69
+ < div class ="blog-date row justify-content-center text-center align-items-center fw-bold p-2 ">
70
+ < strong class ="col-12 p-0 "> 1</ strong >
71
+ < strong class ="col-12 p-0 "> JAN</ strong >
72
+ < strong class ="col-12 p-0 "> 2024</ strong >
73
+ </ div >
74
+ < div class ="d-grid justify-content-start mx-2 " style ="width: 100%; ">
75
+
76
+ < div class ="h6 ">
77
+ Crush Fitness Goals: Quick Tips
78
+ </ div >
79
+ < ul class ="mx-0 d-flex justify-content-between align-items-center small fs-6 " style ="width: 100%; padding-left: 0; margin-left: 0; ">
80
+ < li > < i class ="fa fa-user "> </ i > The King</ li >
81
+ < li > < i class ="fa fa-comment "> </ i > Comments</ li >
82
+ < li > < i class ="fa fa-eye "> </ i > 3 Views</ li >
83
+ </ ul >
84
+ </ div >
85
+ </ div >
86
+ < p class ="fw-normal ">
87
+ Fitness remains up to date with the latest fitness trends and
88
+ innovations, providing users with fresh and relevant content to
89
+ enhance their fitness knowledge.
90
+ </ p >
91
+ < a href ="# " class ="btn btn-danger col-sm-6 col-md-4 "> Read More</ a >
92
+ </ div >
93
+ </ div >
94
+ </ div >
95
+ </ div >
96
+ < div class ="col-sm-6 ">
97
+ < div class ="card ">
98
+
99
+ < div class ="card-img ">
100
+ < img class ="bd-placeholder-img card-img-top " src ="{% static 'img/2.jpeg' %} " alt ="">
101
+ </ div >
102
+
103
+ < div class ="card-body ">
104
+ < div class ="card-content ">
105
+ < div class ="d-sm-flex justify-content-start align-items-center " style ="margin-left: 0; padding-left: 0; ">
106
+ < div class ="blog-date row justify-content-center text-center align-items-center fw-bold p-2 ">
107
+ < strong class ="col-12 p-0 "> 1</ strong >
108
+ < strong class ="col-12 p-0 "> JAN</ strong >
109
+ < strong class ="col-12 p-0 "> 2024</ strong >
110
+ </ div >
111
+ < div class ="d-grid justify-content-start mx-2 " style ="width: 100%; ">
112
+
113
+ < div class ="h6 ">
114
+ Crush Fitness Goals: Quick Tips
115
+ </ div >
116
+ < ul class ="mx-0 d-flex justify-content-between align-items-center small fs-6 " style ="width: 100%; padding-left: 0; margin-left: 0; ">
117
+ < li > < i class ="fa fa-user "> </ i > The King</ li >
118
+ < li > < i class ="fa fa-comment "> </ i > Comments</ li >
119
+ < li > < i class ="fa fa-eye "> </ i > 3 Views</ li >
120
+ </ ul >
121
+ </ div >
122
+ </ div >
123
+ < p class ="fw-normal ">
124
+ Fitness remains up to date with the latest fitness trends and
125
+ innovations, providing users with fresh and relevant content to
126
+ enhance their fitness knowledge.
127
+ </ p >
128
+ < a href ="# " class ="btn btn-danger col-sm-6 col-md-4 "> Read More</ a >
129
+ </ div >
130
+ </ div >
131
+ </ div >
132
+ </ div >
133
+ < div class ="col-sm-6 ">
134
+ < div class ="card ">
135
+
136
+ < div class ="card-img ">
137
+ < img class ="bd-placeholder-img card-img-top " src ="{% static 'img/2.jpeg' %} " alt ="">
138
+ </ div >
139
+
140
+ < div class ="card-body ">
141
+ < div class ="card-content ">
142
+ < div class ="d-sm-flex justify-content-start align-items-center " style ="margin-left: 0; padding-left: 0; ">
143
+ < div class ="blog-date row justify-content-center text-center align-items-center fw-bold p-2 ">
144
+ < strong class ="col-12 p-0 "> 1</ strong >
145
+ < strong class ="col-12 p-0 "> JAN</ strong >
146
+ < strong class ="col-12 p-0 "> 2024</ strong >
147
+ </ div >
148
+ < div class ="d-grid justify-content-start mx-2 " style ="width: 100%; ">
149
+
150
+ < div class ="h6 ">
151
+ Crush Fitness Goals: Quick Tips
152
+ </ div >
153
+ < ul class ="mx-0 d-flex justify-content-between align-items-center small fs-6 " style ="width: 100%; padding-left: 0; margin-left: 0; ">
154
+ < li > < i class ="fa fa-user "> </ i > The King</ li >
155
+ < li > < i class ="fa fa-comment "> </ i > Comments</ li >
156
+ < li > < i class ="fa fa-eye "> </ i > 3 Views</ li >
157
+ </ ul >
158
+ </ div >
159
+ </ div >
160
+ < p class ="fw-normal ">
161
+ Fitness remains up to date with the latest fitness trends and
162
+ innovations, providing users with fresh and relevant content to
163
+ enhance their fitness knowledge.
164
+ </ p >
165
+ < a href ="# " class ="btn btn-danger col-sm-6 col-md-4 "> Read More</ a >
166
+ </ div >
167
+ </ div >
168
+ </ div >
169
+ </ div >
170
+ < div class ="col-sm-6 ">
171
+ < div class ="card ">
172
+
173
+ < div class ="card-img ">
174
+ < img class ="bd-placeholder-img card-img-top " src ="{% static 'img/2.jpeg' %} " alt ="">
175
+ </ div >
176
+
177
+ < div class ="card-body ">
178
+ < div class ="card-content ">
179
+ < div class ="d-sm-flex justify-content-start align-items-center " style ="margin-left: 0; padding-left: 0; ">
180
+ < div class ="blog-date row justify-content-center text-center align-items-center fw-bold p-2 ">
181
+ < strong class ="col-12 p-0 "> 1</ strong >
182
+ < strong class ="col-12 p-0 "> JAN</ strong >
183
+ < strong class ="col-12 p-0 "> 2024</ strong >
184
+ </ div >
185
+ < div class ="d-grid justify-content-start mx-2 " style ="width: 100%; ">
186
+
187
+ < div class ="h6 ">
188
+ Crush Fitness Goals: Quick Tips
189
+ </ div >
190
+ < ul class ="mx-0 d-flex justify-content-between align-items-center small fs-6 " style ="width: 100%; padding-left: 0; margin-left: 0; ">
191
+ < li > < i class ="fa fa-user "> </ i > The King</ li >
192
+ < li > < i class ="fa fa-comment "> </ i > Comments</ li >
193
+ < li > < i class ="fa fa-eye "> </ i > 3 Views</ li >
194
+ </ ul >
195
+ </ div >
196
+ </ div >
197
+ < p class ="fw-normal ">
198
+ Fitness remains up to date with the latest fitness trends and
199
+ innovations, providing users with fresh and relevant content to
200
+ enhance their fitness knowledge.
201
+ </ p >
202
+ < a href ="# " class ="btn btn-danger col-sm-6 col-md-4 "> Read More</ a >
203
+ </ div >
204
+ </ div >
205
+ </ div >
206
+ </ div >
207
+ </ div >
208
+ </ div >
209
+ </ section >
210
+ {% endblock %}
0 commit comments