-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpost.php
42 lines (34 loc) · 808 Bytes
/
post.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
<?php
/**
* Post
*
* Display blog post
*/
/** header */
require 'header.php';
?>
<div class="content-wrapper page-content">
<div class="container">
<div class="py-4"></div>
<div class="row g-4 post">
<?php
$count = $post->countPost('hw_post');
// sort view
if (isset($_GET['view'])) {
$view = $post->sort_view('hw_post');
// sort descending date
} elseif (isset($_GET['descending'])) {
$descending = $post->sort_descending('hw_post');
} else {
// all post
$allPost = $post->allPost();
}
?>
</div>
<div class="py-4"></div>
</div>
</div>
<?php
/** footer*/
require 'footer.php';
?>