Files
resatennis_tyroltenn/IDrive/.config/accountUsage.php

43 lines
1.6 KiB
PHP
Executable File

<?php
include_once 'path.php';
if(!isset($_SESSION['validUser']) || $_SESSION['validUser'] !== true)
exit(header("Location:../index.php"));
$usedQuota ='';
$totalQuota ='';
$percentQuotaUsed ='';
if($_GET['binaryCall'] != 1)
accountUsage();
$usedQuota = $_SESSION['usedQuota'];
$totalQuota = $_SESSION['totalQuota'];
$percentQuotaUsed = (($_SESSION['percentQuotaUsed'] == '')? 0 : $_SESSION['percentQuotaUsed']);
?>
<ul>
<li>Storage used:</li>
<?php if($_SESSION['isSubAccount']) { ?>
<li><span class="used_quota"><b><?php print $usedQuota; ?></b></span></li>
<li class="storage_box">
<div class="<?php print $_SESSION['userName']!=''?'storage_calculate':'disable_calc'; ?>">
<img width="22" height="22" title="Recalculate" alt="Recalculate" src="include/images/spacer.png">
</div>
<div id="rcalcprg">
<img border="0" align="absmiddle" src="include/images/loader_small.gif">
</div>
</li>
<?php } else {?>
<li>
<div class="storage_space"> <span style="width:<?php print $percentQuotaUsed.'%'; ?>;"> space </span> </div>
</li>
<li class="percentage"><?php if(!$_SESSION['isSubAccount']) { print $percentQuotaUsed."%"; } ?></li>
<li class="storage_box">
<div class="<?php print $_SESSION['userName']!=''?'storage_calculate':'disable_calc'; ?>">
<img width="22" height="22" title="Recalculate" alt="Recalculate" src="include/images/spacer.png">
</div>
<div id="rcalcprg">
<img border="0" align="absmiddle" src="include/images/loader_small.gif">
</div>
</li>
<li><span class="used_quota"><?php print $usedQuota; ?></span> of <span class="total_quota"><?php print $totalQuota;?></span></li>
<?php } ?>
</ul>