Beispiel #1
0
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<html>
    <head>
    <?php 
if (session_status() != PHP_SESSION_ACTIVE) {
    session_start();
}
include_once "./Manager/ConnectionManager.php";
include_once "./Manager/ProjectManager.php";
include_once "./Manager/PhotoManager.php";
$project_id = filter_input(INPUT_GET, 'project_id');
$projectMgr = new ProjectManager();
$photoMgr = new PhotoManager();
$hdImages = $photoMgr->getHDPhotosByid($project_id);
$detailImage = $hdImages[0];
$project = $projectMgr->getProject($project_id);
$completionDate = date_create_from_format('Y-m-d H:i:s', $project['completion_date']);
?>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <!-- Latest compiled and minified CSS -->
    <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/css/bootstrap.min.css">
    <link rel="stylesheet" href="http://netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.min.css">
    <link rel="stylesheet" href="./public_html/css/carouselHome.css">
    <link rel="stylesheet" href="./public_html/css/main.css">
    <link rel="stylesheet" href="./public_html/css/dmx_style.css">
    <style>
        .wrapper{
            margin-bottom: 30px;
        }
$pagePosition = ($pageNumber - 1) * $photoPerPage;
//Fetch part of records using SQL LIMIT clause
$results = $photoMgr->getPaginatedResults($pagePosition, $photoPerPage, $project_id);
//Display fetched records
if (!empty($results)) {
    //$_SESSION['results'] = $filteredProjects;
    ?>
        <div id='thumbnails'>
<?php 
    if ($pageNumber == 1) {
        $count = 0;
    } else {
        $count = $pagePosition;
    }
    foreach ($results as $eachPhoto) {
        $hd_photos = $photoMgr->getHDPhotosByid($project_id);
        ?>
            <div class="col-xs-6 col-md-4 detail-thumbnail blur">
                <img class="thumbnail-link" data-img="<?php 
        echo $hd_photos[$count];
        ?>
" src="<?php 
        echo $eachPhoto;
        ?>
">
            </div>
<?php 
        $count++;
    }
    ?>