Пример #1
0
function build_rbpi($response)
{
    $response['rbpi']['hostname'] = Rbpi::hostname(true);
    $response['rbpi']['distribution'] = Rbpi::distribution();
    $response['rbpi']['kernel'] = Rbpi::kernel();
    $response['rbpi']['firmware'] = Rbpi::firmware();
    $response['rbpi']['ip']['internal'] = Rbpi::internalIp();
    $response['rbpi']['ip']['external'] = Rbpi::externalIp();
    return $response;
}
Пример #2
0
    foreach ($shellExecOutput as &$item) {
        $item = '<tr><td>' . preg_replace('/\\s+/', '</td><td>', $item, $columnCount) . '</td></tr>';
    }
    // return the build table
    return '<table class=\'table table-striped\'>' . '<thead>' . $tableHead . '</thead>' . '<tbody>' . implode($shellExecOutput) . '</tbody>' . '</table>';
}
?>
<div class="container details">

    <table>
        <tr id="check-system">
            <td class="check"><i class="icon-cog"></i> System</td>
            <td class="icon"></td>
            <td class="infos">
                hostname: <span class="text-info"><?php 
echo Rbpi::hostname(true);
?>
</span>
                <br />distribution: <span class="text-info"><?php 
echo Rbpi::distribution();
?>
</span>
                <br />kernel: <?php 
echo Rbpi::kernel();
?>
                <br />firmware: <?php 
echo Rbpi::firmware();
?>
            </td>
        </tr>
Пример #3
0
            break;
        case 'warning':
            echo 'warning-sign';
            break;
        default:
            echo 'exclamation-sign';
    }
    echo ' pull-right"></i>';
}
?>

<div class="container home">
    <div class="row-fluid infos">
        <div class="span4">
            <i class="icon-home"></i> <?php 
echo Rbpi::hostname();
?>
        </div>
        <div class="span4">
            <i class="icon-map-marker"></i> <?php 
echo Rbpi::internalIp();
?>
            <?php 
echo $external_ip != 'Unavailable' ? '<br /><i class="icon-globe"></i> ' . $external_ip : '';
?>
        </div>
        <div class="span4">
            <i class="icon-play-circle"></i> Server <?php 
echo Rbpi::webServer();
?>
        </div>