-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.php
More file actions
104 lines (100 loc) · 2.58 KB
/
index.php
File metadata and controls
104 lines (100 loc) · 2.58 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
96
97
98
99
100
101
102
103
104
<?php
$query = $_SERVER['QUERY_STRING'];
$head = fopen("head.html","r");
$headdata = "";
$bodydata = "";
$taildata = "";
switch($query) {
case 1:
$body = fopen("main.html", "r");
for ($i = 0; $i < 40; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?1" name="home">Home</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
case 2:
$body = fopen("events.html", "r");
for ($i = 0; $i < 41; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?2" name="events">Events</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
case 3:
$body = fopen("media.html", "r");
for ($i = 0; $i < 42; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?3" name="media">Media</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
case 4:
$body = fopen("sponsors.html", "r");
for ($i = 0; $i < 43; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?4" name="sponsor">Sponsorship</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
case 5:
$body = fopen("about.html", "r");
for ($i = 0; $i < 44; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?5" name="about">About</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
case 6:
$body = fopen("contact.html", "r");
for ($i = 0; $i < 45; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?6" name="contact">Contact</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
default:
$body = fopen("main.html", "r");
for ($i = 0; $i < 40; $i++) {
$headdata .= fgets($head);
}
$headdata .= '<li class=active><a href="index.php?1" name="home">Home</a></li>';
$a = fgets($head);
while (!feof($head)) {
$headdata .= fgets($head);
}
break;
}
$tail = fopen("tail.html","r");
/*while (!feof($head)) {
$headdata .= fgets($head);
}*/
while (!feof($body)) {
$bodydata .= fgets($body);
}
while (!feof($tail)) {
$taildata .= fgets($tail);
}
fclose($head);
fclose($body);
fclose($tail);
echo $headdata . $bodydata . $taildata;
?>