Definition:
function display_space_usage() {}
Source code
function display_space_usage() {
$space = get_space_allowed();
$used = get_dirsize( BLOGUPLOADDIR ) / 1024 / 1024;
$percentused = ( $used / $space ) * 100;
if ( $space > 1000 ) {
$space = number_format( $space / 1024 );
/* translators: Gigabytes */
$space .= __( 'GB' );
} else {
/* translators: Megabytes */
$space .= __( 'MB' );
}
?>
<strong><?php printf( __( 'Used: %1s%% of %2s' ), number_format( $percentused ), $space ); ?></strong>
<?php
}
928

February 11, 2011 


No comments yet... Be the first to leave a reply!