-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.php
53 lines (43 loc) · 1016 Bytes
/
index.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
<?php
include "function.php";
include "config.php";
function getfiles($gg){
$path="./code/$gg";
foreach(scandir($path) as $afile)
{
if($afile=='.'||$afile=='..') continue;
$nowf=substr($afile,0,strlen($afile)-4);
echo "<a href=\"./source/$gg/$nowf.cpp\">".$nowf."</a><br/>";
}
}
function getfiles2($path){
foreach(scandir($path) as $afile)
{
if($afile=='.'||$afile=='..') continue;
echo "<a href=\"./result/$afile\">".$afile."</a><br/>";
}
}
function getfiles3($path){
foreach(scandir($path) as $afile)
{
if($afile=='.'||$afile=='..') continue;
echo "<a href=\"./map/$afile\">".$afile."</a><br/>";
}
}
//echo "<h2>大家好~这里是地灵殿的日常捉迷藏游戏</h2><br/>";
echo "<h2>Satori</h2><br/>";
getfiles("satori");
echo "<h2>Koishi</h2><br/>";
getfiles("koishi");
?>
<br/><br/><br/>
<a href='./upload.php'>upload code</a><br/>
<a href='./create.php'>create game</a><br/>
<br/>map<br/>
<?php
getfiles3("./map");
?>
<br/>result<br/>
<?php
getfiles2("./result");
?>