part.setquota.php 1.2 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <div class="quota">
  2. <!-- Default storage -->
  3. <span><?php p($l->t('Default quota'));?></span>
  4. <?php if((bool) $_['isAdmin']): ?>
  5. <select id='default_quota' data-inputtitle="<?php p($l->t('Please enter storage quota (ex: "512 MB" or "12 GB")')) ?>" data-tipsy-gravity="s">
  6. <option <?php if($_['default_quota'] === 'none') print_unescaped('selected="selected"');?> value='none'>
  7. <?php p($l->t('Unlimited'));?>
  8. </option>
  9. <?php foreach($_['quota_preset'] as $preset):?>
  10. <?php if($preset !== 'default'):?>
  11. <option <?php if($_['default_quota']==$preset) print_unescaped('selected="selected"');?> value='<?php p($preset);?>'>
  12. <?php p($preset);?>
  13. </option>
  14. <?php endif;?>
  15. <?php endforeach;?>
  16. <?php if($_['defaultQuotaIsUserDefined']):?>
  17. <option selected="selected" value='<?php p($_['default_quota']);?>'>
  18. <?php p($_['default_quota']);?>
  19. </option>
  20. <?php endif;?>
  21. <option data-new value='other'>
  22. <?php p($l->t('Other'));?>
  23. ...
  24. </option>
  25. </select>
  26. <?php endif; ?>
  27. <?php if((bool) !$_['isAdmin']): ?>
  28. :
  29. <?php if( $_['default_quota'] === 'none'): ?>
  30. <?php p($l->t('Unlimited'));?>
  31. <?php else: ?>
  32. <?php p($_['default_quota']);?>
  33. <?php endif; ?>
  34. <?php endif; ?>
  35. </div>