-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathfiltered_posts.php
More file actions
75 lines (54 loc) · 1.86 KB
/
Copy pathfiltered_posts.php
File metadata and controls
75 lines (54 loc) · 1.86 KB
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
<?php include('config.php'); ?>
<?php include('includes/public_functions.php'); ?>
<?php include('includes/head_section.php'); ?>
<?php
// dohvati post od teme
if (isset($_GET['topic'])) {
$topic_id = $_GET['topic'];
$posts = getPublishedPostsByTopic($topic_id);
}
?>
<title>NK Croatia Zmijavci </title>
</head>
<body>
<div class="row">
<!-- banner -->
<?php include( ROOT_PATH . '/includes/banner.php') ?>
<!-- // banner -->
<!-- Navbar -->
<?php include( ROOT_PATH . '/includes/navbar.php'); ?>
<!-- // Navbar -->
<!-- Naslovna -->
<div class="row">
<div class="center spec">
<img class="aleft" src="vijesti/thumb.jpg" style="height:250px; width:760px" alt="">
<span class="upper spec hide"> VIJESTI </span>
<h1 class="title spec hide"> <?php echo getTopicNameById($topic_id); ?> </h1>
<div class="clearfix"></div>
</div>
</div>
<div class="clearfix"></div>
<!-- Sadrzaj s vijestima -->
<div class="row main-container">
<div class="center">
<div class="">
<?php foreach ($posts as $post): ?>
<a href="single_post.php?post-slug=<?php echo $post['slug']; ?>" class="w30">
<img src="<?php echo BASE_URL . '/static/images/' . $post['image']; ?>" alt="" style="width:100%;" >
<span class="news-date">
<?php echo date("j.m. Y ", strtotime($post["created_at"])); ?>
</span>
<span class="news-title" style="height: 80px;"><?php echo $post['title'] ?></span>
<span class="plus-left"></span>
<span class="plus-top"></span>
</a>
<?php endforeach ?>
</div>
</div>
</div>
<!-- KRAJ VIJESTI -->
</div>
<!-- // container -->
<!-- Footer -->
<?php include( ROOT_PATH . '/includes/footeri.php'); ?>
<!-- // Footer -->