-
Notifications
You must be signed in to change notification settings - Fork 5
/
Copy pathidols.php.
64 lines (50 loc) · 1.57 KB
/
idols.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
<?php include 'header.php'; ?>
<!-- start body -->
<body onunload="">
<!-- start dotted pattern -->
<div class="bg-overlay"></div>
<!-- end dotted pattern -->
<!-- start navigation -->
<?php include('menu.php'); ?>
<!-- end navigation -->
<!-- start content wrapper -->
<div class="content page-content">
<?php
if(isset($_GET['id'])) {
$id = (int)$_GET['id'];
$t = $db->prepare("SELECT * FROM idols WHERE idolid = '$id'");
$t->execute();
if($t->rowCount() == 1) {
$row = $t->fetch(PDO::FETCH_ASSOC);
$title = 'Idol of '.$row['tirthankar'];
} else {
$title = 'Idols';
}
} else {
$title = 'Idols';
}
?>
<div class="page-title">
<h1><span><?php echo $title; ?></span></h1>
</div>
<div class="divider clear"></div>
<div class="inner-content">
<?php if($title=='Idols') { ?>
<h4>List of All Digambar Jain Deity Idols is given Below. Click on the name to see more information</h4>
<input id="searchIdols" name="searchBox" type="text" class="fullWidth" />
<div id="searchResults" class="hoverImg"></div>
<script type="text/javascript" src="js/searchIdols.js"></script>
<?php
} else {
$templeid = $row['templeid'];
$t2 = $db->prepare("SELECT * FROM temples WHERE tid = '$templeid'");
$t2->execute();
if($t2->rowCount() == 1) {
$row2 = $t2->fetch(PDO::FETCH_ASSOC);
}
echo 'Temple: <a href="temples.php?id='.$templeid.'" title="'.$row2['tname'].'">'.$row2['tname'].'</a>';
}
?>
</div>
</div><!-- end content wrapper -->
<?php include 'footer.php'; ?>