Show Memory Usage page number formatting

Discussion in 'General' started by kerrsmith, Sep 3, 2015.

  1. kerrsmith

    kerrsmith Member

    When on the Show Memory Usage page it would be good if the numbers shown were also in KB and MB as well as they are currently, this value could maybe be in brackets just after them at the end of the line.

    Which file is it that deals with this as I would like to make this change on my server so it is easy to see the memory usage at a glance?

    I have added this suggestion to the bug tracker / feature request for consideration as well, just in case any one else thinks it may be useful.

    http://bugtracker.ispconfig.org/ind...=&openedfrom=&openedto=&closedfrom=&closedto=
     
    Last edited: Sep 10, 2015
    till likes this.
  2. kerrsmith

    kerrsmith Member

    The file used to display the memory usage data is:

    \interface\lib\classes\tools_monitor.inc.php

    At line 121 the function showMemUsage () is where the relevant code is.

    For my server I have modified this function to display the information in this format - MemTotal: 518492160 (494M)

    ...
    ...
    if ($key != '') {
    $memory = number_format($value / 1048576);
    $html .= '<tr>
    <td>' . $key . ':</td>
    <td>' . $value . ' (' . $memory . 'M)</td>
    </tr>';
    }
    ...
    ...
     
    till likes this.

Share This Page