-
Notifications
You must be signed in to change notification settings - Fork 0
/
categories.php
49 lines (44 loc) · 1.18 KB
/
categories.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
<?php
$title = 'ExpertSystem';
include 'views/layout/header.php';
?>
<style>
.main_page {
padding-top: 40px;
}
</style>
<div class="container">
<div class="row main_page">
<div class="col-md-12 main_side">
<?php
$query = "SELECT * FROM categories";
foreach ($con->query($query) as $row) {
// while ($row = $stnt->fetch(PDO::FETCH_ASSOC)) {
$cat_id = $row['id'];
$cat_title = $row['cat_title'];
$cat_body =$row['cat_body'];
$cat_tags =$row['cat_tags'];
?>
<div class="col-md-6">
<div class="panel-group">
<div class="panel panel-info">
<div class="panel-heading">
<p class="panel-title center"><?php echo $cat_title; ?></p>
</div>
<div class="panel-body">
<p><?php //echo $cat_body; ?></p>
<p>Other Online resources</p>
<p><?php echo $cat_tags; ?></p>
<a href="symptoms.php?id=<?php echo $cat_id; ?>" class="btn btn-info"> View Questions</a>
</div>
</div>
</div>
</div>
<?php
}
?>
</div>
</div>
<?php
include 'views/layout/footer.php'
?>