-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.php
99 lines (87 loc) · 3.33 KB
/
main.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
<?php
/**
* Created by IntelliJ IDEA.
* User: Jean-Mathieu
* Date: 1/17/2016
* Time: 3:02 PM
*/
include("head.php");
include ("data.php");
?>
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
<!-- Indicators -->
<ol class="carousel-indicators">
<?php
$i = 0;
foreach($data as $d){
if($d['picture'] != "img/sorry.jpg"){
?>
<li data-target="#carousel-example-generic" data-slide-to="<?=$i?>" <?php if($i == 0) echo 'class="active"' ?>></li>
<?php $i++; }} ?>
</ol>
<!-- Wrapper for slides -->
<div class="carousel-inner" role="listbox">
<?php
$i = 0;
foreach($data as $d){ $i++;
if($d['picture'] != "img/sorry.jpg"){
?>
<div class="item <?php if($i == 1) echo "active" ?>">
<img src="<?=$d['picture']?>" alt="<?=$d['title']?>">
<div class="carousel-caption">
<?php if($d['link'] != null){ ?>
<a href="<?=$d['link']?>" style="text-decoration: none;" target="_blank"><h3><?=$d['title']?></h3></a>
<?php }else{ ?>
<h3><?=$d['title']?></h3>
<?php } ?>
<p><?=$d['sub_title']?></p>
</div>
</div>
<?php }
} ?>
</div>
<!-- Controls -->
<a class="left carousel-control" href="#carousel-example-generic" role="button" data-slide="prev">
<span class="glyphicon glyphicon-chevron-left" aria-hidden="true"></span>
<span class="sr-only">Previous</span>
</a>
<a class="right carousel-control" href="#carousel-example-generic" role="button" data-slide="next">
<span class="glyphicon glyphicon-chevron-right" aria-hidden="true"></span>
<span class="sr-only">Next</span>
</a>
</div>
<!-- Page Heading -->
<div class="row">
<div class="col-lg-12">
<h1 class="page-header">Projects</h1>
</div>
</div>
<!-- /.row -->
<?php
$i = 0;
foreach($data as $d){ $i++?>
<!-- Project <?=$i?> -->
<div class="row">
<div class="col-md-7">
<img class="img-responsive portfolio" src="<?=$d['picture']?>" alt="">
</div>
<div class="col-md-5">
<h3><?=$d['title']?></h3>
<h4><?=$d['sub_title']?></h4>
<p><?=$d['description']?></p>
<?php if(strlen($d['link']) > 0){ ?>
<p><a class="btn btn-primary" href="<?=$d['link']?>" target="_blank">View Project <span class="glyphicon glyphicon-chevron-right"></span></a></p>
<?php } ?>
<?php
if(strlen($d['github']) > 0){ ?>
<p><a class="btn btn-primary" href="<?=$d['github']?>" target="_blank">View Source Code <span class="glyphicon glyphicon-console"></span></a></p>
<?php } ?>
</div>
</div>
<!-- /.row -->
<hr>
<?php } ?>
<br>
<p>Last Updated On <?=date ("F d Y H:i:s.", filemtime("main.php"))?></p>
<hr>
<?php include ("foot.php");