-
Notifications
You must be signed in to change notification settings - Fork 14
/
Copy pathupload.php
67 lines (62 loc) · 1.3 KB
/
upload.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
<?php
if(isset($_FILES['image'])){
$errors= array();
$file_name = $_FILES['image']['name'];
$file_tmp =$_FILES['image']['tmp_name'];
$file_type=$_FILES['image']['type'];
$file_ext=strtolower(end(explode('.',$_FILES['image']['name'])));
$extensions= array("txt");
move_uploaded_file($file_tmp,"upload/".$file_name);
}
?>
<html>
<head>
<style>
table {
font-family: arial, sans-serif;
border-collapse: collapse;
width: 100%;
}
td, th {
border: 1px solid #dddddd;
text-align: left;
padding: 8px;
}
tr:nth-child(even) {
background-color: #dddddd;
}
</style>
</head>
<body>
<table>
<tr>
<th background="wafaray_image.png">
<font size="+3"><p style="font-style:normal;color:yellow;font-family:Monospace;font-weight:normal;">
.text: WARAFAY <br>
.data: Welcom3! <br>
.rsrc: Malware Detection
</p></font>
</th>
</tr>
<tr>
<th><h3>Upload your file</h3></th>
</tr>
<tr>
<th>
<form action="" method="POST" enctype="multipart/form-data">
<input type="file" name="image" /></br></br>
<input type="submit"/></br>
</form>
</th>
</tr>
<tr>
<th>RESULT: </br>
<ul>
<li>Sent file: <?php echo $_FILES['image']['name']; ?>
<li>File type: <?php echo $_FILES['image']['type'] ?>
</ul>
</th>
</tr>
</table>
</body>
</html>