2017-12-03 21:59:23 -06:00
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
|
2017-12-03 22:20:10 -06:00
|
|
|
<!-- THIS ENTIRE FILE IS UNDER THE GNU AGPLv3+
|
2017-12-03 21:59:23 -06:00
|
|
|
https://www.gnu.org/licenses/agpl-3.0.html -->
|
|
|
|
|
2017-12-19 15:07:09 -06:00
|
|
|
<link rel="stylesheet" media="screen" href="https://fontlibrary.org/face/connection" type="text/css"/>
|
2017-12-03 21:59:23 -06:00
|
|
|
<link rel="stylesheet" type="text/css" href="../../res/bootstrap.css">
|
|
|
|
<link rel="stylesheet" type="text/css" href="../../res/style.css">
|
2017-12-19 15:07:09 -06:00
|
|
|
<link rel="shortcut icon" href="../../res/img/coin.ico">
|
2017-12-03 21:59:23 -06:00
|
|
|
</head>
|
|
|
|
|
|
|
|
<body style="font-family: 'ConnectionRegular'; font-weight: normal; font-style: normal;">
|
|
|
|
<div class="row text-center">
|
|
|
|
<a href="../mazes/">
|
|
|
|
<div class="col-md-4 col-lg-4" id="sectiona">
|
|
|
|
<h1>ihatemazes</h1>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<a href="../naia/">
|
|
|
|
<div class="col-md-4 col-lg-4" id="sectionb">
|
|
|
|
<h1>naia</h1>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
|
|
|
|
<a href="../files/">
|
|
|
|
<div class="col-md-4 col-lg-4" id="sectionc">
|
|
|
|
<h1>image-file_upload</h1>
|
|
|
|
</div>
|
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<center style="margin-top: 30px">
|
|
|
|
|
|
|
|
|
|
|
|
<?php
|
2017-12-03 22:20:10 -06:00
|
|
|
|
2017-12-19 15:07:09 -06:00
|
|
|
if (empty($_POST["desired_filename"]))
|
|
|
|
{
|
|
|
|
$file_name = $_FILES["fileToUpload"]["name"];
|
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
|
|
|
$file_name = $_POST["desired_filename"];
|
|
|
|
}
|
2017-12-03 22:20:10 -06:00
|
|
|
|
2017-12-19 15:07:09 -06:00
|
|
|
|
|
|
|
// check if file-name has any... undesirable characteristics
|
2017-12-03 22:20:10 -06:00
|
|
|
|
|
|
|
if (strstr($file_name, " "))
|
|
|
|
{
|
|
|
|
$file_name = str_replace(" ", "_", $file_name);
|
|
|
|
}
|
|
|
|
|
|
|
|
if (strstr($file_name, ".."))
|
|
|
|
{
|
|
|
|
$file_name = str_replace("..", "_", $file_name);
|
|
|
|
}
|
|
|
|
|
|
|
|
if (strstr($file_name, "/"))
|
|
|
|
{
|
|
|
|
$file_name = str_replace("/", "_", $file_name);
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// and now we pretend that never happened
|
|
|
|
|
2017-12-03 21:59:23 -06:00
|
|
|
$dest_dir = "p/";
|
2017-12-03 22:20:10 -06:00
|
|
|
$dest_file = $dest_dir . $file_name;
|
|
|
|
|
2017-12-03 21:59:23 -06:00
|
|
|
$beaming_permitted = 1;
|
|
|
|
|
|
|
|
if (file_exists($dest_file))
|
|
|
|
{
|
|
|
|
echo "<p>WE'RE GETTING SOME INTERFERENCE</p>";
|
|
|
|
echo "<p>PLEASE USE A DIFFERENT COIN-NAME</p>";
|
|
|
|
$beaming_permitted = 0;
|
|
|
|
}
|
|
|
|
elseif ($_FILES["fileToUpload"]["size"] > 50000000)
|
|
|
|
{
|
|
|
|
echo "<p>THIS COIN WILL BE UP FOR AT LEAST THREE MONTHS</p>";
|
|
|
|
echo "<p>7 MOONS IN THE ORDINARY SABBATICAL CYCLE</p>";
|
|
|
|
echo "<p>AFTER THAT, IT *MAY* BE DE-ATOMIZED</p>>";
|
|
|
|
}
|
|
|
|
elseif ($_FILES["fileToUpload"]["size"] < 25000000)
|
|
|
|
{
|
|
|
|
echo "<p>THANK YOU FOR FEEDING ME</p>";
|
|
|
|
echo "<p>YOUR COIN IS IN SAFE HANDS</p>";
|
|
|
|
echo "<p>IT WILL NOT BE DE-ATOMIZED FOR AT LEAST A YEAR</p>";
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if ($beaming_permitted == 0) {
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<img src=../../res/img/coinfire_big.png>";
|
2017-12-03 21:59:23 -06:00
|
|
|
echo "<p>sorry <\\3</p>";
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<title>COIN ON FIRE</title>";
|
2017-12-03 21:59:23 -06:00
|
|
|
}
|
|
|
|
else {
|
|
|
|
if (move_uploaded_file($_FILES["fileToUpload"]["tmp_name"],$dest_file)) {
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<img src=../../res/img/coininserted_big.png>";
|
2017-12-03 21:59:23 -06:00
|
|
|
echo "<p>IT IS <a href=" . $dest_file . ">HERE</a></p>";
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<title>COIN INSERTED <3</title>";
|
2017-12-03 21:59:23 -06:00
|
|
|
}
|
|
|
|
else
|
|
|
|
{
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<img src=../../res/img/coinfire_big.png>";
|
2017-12-03 21:59:23 -06:00
|
|
|
echo "<p>...</p>";
|
|
|
|
echo "<p>THAT WAS WEIRD, SOMETHING WENT WRONG. TRY AGAIN.</p>";
|
2017-12-19 15:07:09 -06:00
|
|
|
echo "<title>COIN ON FIRE</title>";
|
2017-12-03 21:59:23 -06:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
?>
|
|
|
|
|
|
|
|
</center>
|
|
|
|
</body>
|
|
|
|
</html>
|