/
types.php
113 lines (101 loc) · 2.92 KB
/
types.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
107
108
109
110
111
112
113
<!DOCTYPE HTML>
<html>
<head>
<title>PokeGuide</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<meta name="description" content="" />
<meta name="keywords" content="" />
<link href='http://fonts.googleapis.com/css?family=Ubuntu+Condensed' rel='stylesheet' type='text/css'>
<script src="js/jquery.min.js"></script>
<script src="js/config.js"></script>
<script src="js/skel.min.js"></script>
<script src="js/skel-panels.min.js"></script>
<noscript>
<link rel="stylesheet" href="css/skel-noscript.css" />
<link rel="stylesheet" href="css/style.css" />
<link rel="stylesheet" href="css/style-desktop.css" />
</noscript>
<!--[if lte IE 9]><link rel="stylesheet" href="css/ie9.css" /><![endif]-->
<!--[if lte IE 8]><script src="js/html5shiv.js"></script><![endif]-->
<link rel="stylesheet" href="cssmain/types.css" />
</head>
<body>
<!-- ********************************************************* -->
<div id="header-wrapper">
<div class="container">
<div class="row">
<div class="12u">
<?php require 'topMenubar.php';?>
</div>
</div>
</div>
</div>
<div id="main">
<div class="container">
<div class="row main-row">
<div class="12u">
<h2 style='text-align:center;'>Pokemon Weakness Type Chart</h2>
<div class="Pokeguide">
<?php
//EXTRACT DATA FROM TYPES TABLE
$Type_is = executePlainSQL("SELECT * from type_is");
echo "<table>";
echo "<tr><td>Attack\Defense</td>";
//=============FIRST ROW FOR THE TABLES
while($row = OCI_Fetch_Array($Type_is,OCI_BOTH))
{
if($row[0] !='Nothing')
echo "<td>$row[0]</td>";
}
//=========================
echo "</tr>";
//=============REST OF ROWS
$RestType = executePlainSQL("SELECT * from type_is");
//REST OF THE TABLE
while($row = OCI_Fetch_Array($RestType,OCI_BOTH))
{
if($row[0] !='Nothing')
{
echo "<tr>";
for($x=0; $x < 16; $x++)
{
if($row[$x]==2)
echo "<td bgcolor='#00CC00'>{$row[$x]}</td>";
else if($row[$x]==.5)
echo "<td bgcolor='#FF0000'>{$row[$x]}</td>";
else if($row[$x]==0)
echo "<td bgcolor='#C2C2A3'>{$row[$x]}</td>";
else
echo "<td>{$row[$x]}</td>";
}
echo "</tr>";
}
}
//=============================
echo "</table>";
?>
</div>
</div>
</div>
</div>
</div>
<div id="footer-wrapper">
<div class="container">
<div class="row">
<div class="8u">
</div>
<div class="4u">
</div>
</div>
<div class="row">
<div class="12u">
<div id="copyright">
© CS304 - PokeGuide. All rights reserved. | Design: HTML5 UP | Images: fotogrph
</div>
</div>
</div>
</div>
</div>
<!-- ********************************************************* -->
</body>
</html>