Probleem met ?switch?variable?
De code is:
Code (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
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
case 3:
$extlimit = "no"; //Do you want to limit the extensions of files uploaded
$limitedext = array(".torrent"); //Extensions you want files uploaded limited to.
$sizelimit = "yes"; //Do you want a size limit, yes or no?
$sizebytes = "100000"; //size limit in bytes
$dl = "http://www.psycho-project.com/wallpapers"; //url where files are uploaded
$absolute_path = "/home/psycho/public_html/wallpapers/"; //Absolute path to where files are uploaded
$websiteurl = "http://www.psycho-project.com"; //Url to you website
$websitename = "Psycho-Project";
if($action=='0') {
echo"
<form method=POST action=$PHP_SELF?do=wallpapers&mode=3&action=1 enctype=multipart/form-data>
<p>File to upload:<br>
<input type=file name=file size=30>
<p><button TYPE=submit NAME=submit>
Upload
</button>
</form>";
}
if($action=='1') {
$dir = "wallpapers";
if ($file != "") {
if (file_exists("$absolute_path/$file_name")) {
die("File already exists");
}
if (($sizelimit == "yes") && ($file_size > $sizebytes)) {
die("File is to big. It must be $sizebytes bytes or less.");
}
$ext = strrchr($file_name,'.');
if (($extlimit == "yes") && (!in_array($ext,$limitedext))) {
die("The file you are uploading doesn't have the correct extension.");
}
@copy($file, "$absolute_path/$file_name") or die("The file you are trying to upload couldn't be copied to the server");
} else {
die("Must select file to upload");
}
echo "
<html>
<head>
<title>File Uploaded</title>
</head>
<body>";
echo $file_name." was uploaded";
echo "<br>
<a href=$PHP_SELF?do=wallpapers&mode=3&action=0>Upload Another File</a>
</body>
</html>";
}
break;
$extlimit = "no"; //Do you want to limit the extensions of files uploaded
$limitedext = array(".torrent"); //Extensions you want files uploaded limited to.
$sizelimit = "yes"; //Do you want a size limit, yes or no?
$sizebytes = "100000"; //size limit in bytes
$dl = "http://www.psycho-project.com/wallpapers"; //url where files are uploaded
$absolute_path = "/home/psycho/public_html/wallpapers/"; //Absolute path to where files are uploaded
$websiteurl = "http://www.psycho-project.com"; //Url to you website
$websitename = "Psycho-Project";
if($action=='0') {
echo"
<form method=POST action=$PHP_SELF?do=wallpapers&mode=3&action=1 enctype=multipart/form-data>
<p>File to upload:<br>
<input type=file name=file size=30>
<p><button TYPE=submit NAME=submit>
Upload
</button>
</form>";
}
if($action=='1') {
$dir = "wallpapers";
if ($file != "") {
if (file_exists("$absolute_path/$file_name")) {
die("File already exists");
}
if (($sizelimit == "yes") && ($file_size > $sizebytes)) {
die("File is to big. It must be $sizebytes bytes or less.");
}
$ext = strrchr($file_name,'.');
if (($extlimit == "yes") && (!in_array($ext,$limitedext))) {
die("The file you are uploading doesn't have the correct extension.");
}
@copy($file, "$absolute_path/$file_name") or die("The file you are trying to upload couldn't be copied to the server");
} else {
die("Must select file to upload");
}
echo "
<html>
<head>
<title>File Uploaded</title>
</head>
<body>";
echo $file_name." was uploaded";
echo "<br>
<a href=$PHP_SELF?do=wallpapers&mode=3&action=0>Upload Another File</a>
</body>
</html>";
}
break;
De link naar de page met het probleem is:
http://www.psycho-project.com/main_index.php?do=wallpaper&mode=3&action=0
niemand die iets weet op dit probleem? :(
Dit dus ipv:
:)