forked from lkiddell/3512_Assignment_2
-
Notifications
You must be signed in to change notification settings - Fork 0
/
single-image.php
106 lines (85 loc) · 3.23 KB
/
single-image.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
<?php
session_start();
include_once "functions.php";
if ( !isset($_GET['id']))
header("Location: error.php");
?>
<!DOCTYPE html>
<html lang="en">
<head>
<!-- Google fonts used in this theme -->
<link href='http://fonts.googleapis.com/css?family=Open+Sans+Condensed:700' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,400,800,600,700,300' rel='stylesheet' type='text/css'>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="">
<meta name="author" content="">
<link rel="shortcut icon" href="../../assets/ico/favicon.png">
<title>Assignment 1</title>
<!-- Bootstrap core CSS -->
<link href="bootstrap3_travelTheme/dist/css/bootstrap.min.css" rel="stylesheet">
<!-- Custom styles for this template -->
<link href="bootstrap3_travelTheme/theme.css" rel="stylesheet">
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="bootstrap3_travelTheme/assets/js/html5shiv.js"></script>
<script src="bootstrap3_travelTheme/assets/js/respond.min.js"></script>
<![endif]-->
</head>
<body>
<?php
include "includes/travel-header.inc.php";
?>
<div class="container"> <!-- start main content container -->
<div class="row"> <!-- start main content row -->
<div class="col-md-3">
<?php
include "includes/travel-left-rail.inc.php";
$posts = findImageRow();
$name = $posts['FirstName'] . " " . $posts['LastName'];
?>
</div>
<div class="col-md-7"> <!-- start main content column -->
<ol class="breadcrumb">
<li><a href="index.php">Home</a></li>
<li><a href="browse.php">Browse</a></li>
<li><a href="browse-images.php">Images</a></li>
<li><a href="#" class="active"><?php echo $posts['Title']; ?></a></li>
</ol>
<div> <!-- Post description-->
<?php
echo "<h2>". $posts['Title'] . "</h2></br>";
?>
</div>
<div class="well">
<div class="row">
<?php
$pdo = databaseConnection();
$sql = "SELECT * FROM TravelImage \n"
. "INNER JOIN TravelImageDetails \n"
. "ON TravelImageDetails.ImageID = TravelImage.ImageID \n"
. "WHERE TravelImage.ImageID = " . $_GET['id'];
$result = $pdo->query($sql);
largeImage($result);
$pdo = null;
?>
</div>
</div>
<div>
<?php
echo "<p>" . $posts['Description'] . "</p>";
?>
</div>
</div> <!-- end main content column -->
<div class="col-md-2">
<?php include "includes/travel-right-rail-image.inc.php";?>
</div>
</div> <!-- end main content row -->
</div> <!-- end main content container -->
<?php
include "includes/travel-footer.inc.php";
?>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<script src="bootstrap3_travelTheme/dist/js/bootstrap.min.js"></script>
</body>
</html>