This repository was archived by the owner on Mar 15, 2023. It is now read-only.
Repository navigation
Expand file tree
/
Copy pathstatistics.php
More file actions
95 lines (74 loc) · 2.37 KB
/
Copy pathstatistics.php
File metadata and controls
95 lines (74 loc) · 2.37 KB
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
<?php
include 'header.php';
include 'connect.php';
$php_var = 10;
$php_sd = 50;
$Genderm = mysql_query("select Gender from entry where Gender = 'Male'");
$Genderm_num_rows = mysql_num_rows($Genderm);
echo "$Genderm_num_rows";
$Genderf = mysql_query("select Gender from entry where Gender = 'Female'");
$Genderf_num_rows = mysql_num_rows($Genderf);
echo "$Genderf_num_rows";
?>
<script src="/rdb/chart/Chart.js"></script>
<!-- formee-->
<div class="container">
<div class="box-add">
<div class="box-sec">
<canvas id="canvas-gender" height="400" width="400"></canvas>
<table class="right table" style="width:300px;"><thead class="table-head"><tr><th>Gender</th><th>Count</th></tr></thead>
<tbody class='table-body'>
<tr>
<td>
<span style="color:#615F5C;">█</span> Male
</td>
<td>
<? echo "$Genderm_num_rows"; ?>
</td>
</tr>
<tr>
<td>
<span style="color:#C8C0B6;">█</span> Female
</td>
<td>
<? echo "$Genderf_num_rows"; ?>
</td>
</tr>
</tbody>
</table>
</div>
<div class="box-sec">
<canvas id="canvas" height="450" width="450"></canvas>
</div>
</div>
</div>
<!-- formee-->
<!-- Load JS here for greater good =============================-->
<script>
var pieData = [
{
value: <? echo $Genderm_num_rows; ?>,
color:"#807E7B"
},
{
value : <? echo $Genderf_num_rows; ?>,
color : "#D3CCC3"
}
];
var myPie = new Chart(document.getElementById("canvas-gender").getContext("2d")).Pie(pieData);
var myExp = new Chart(document.getElementById("canvas-exp").getContext("2d")).Pie(pieData);
</script>
<script src="js/jquery-1.8.3.min.js"></script>
<script src="js/jquery-ui-1.10.3.custom.min.js"></script>
<script src="js/jquery.ui.touch-punch.min.js"></script>
<script src="js/bootstrap.min.js"></script>
<script src="js/bootstrap-select.js"></script>
<script src="js/bootstrap-switch.js"></script>
<script src="js/flatui-checkbox.js"></script>
<script src="js/flatui-radio.js"></script>
<script src="js/jquery.tagsinput.js"></script>
<script src="js/jquery.placeholder.js"></script>
<script src="js/jquery.stacktable.js"></script>
<script src="js/application.js"></script>
</body>
</html>