示例#1
0
文件: index.php 项目: rockylo/MoZBX
<div class="navbar navbar-fixed-top">
  <div class="navbar-inner">
    <div class="container">
      <a class="brand" href="#">MoZBX</a>
    </div>
  </div>
</div>

<div class="container">
    <h2>Login</h2>
    <form method="post" action="index.php" class="form-horizontal" >
        <fieldset>
        <?php 
    if (isset($_POST['zabbixUsername'])) {
        // POST variables set, but still showing the form. Invalid credentials?
        if (count($zabbix->getLastError()) > 0) {
            $arrError = $zabbix->getLastError();
            $errormsg = $arrError["data"];
        } else {
            $errormsg = "invalid combination";
        }
        ?>
            <div class="alert alert-error">
                <?php 
        echo $errormsg;
        ?>
            </div>
            <?php 
    }
    if ($arrSettings["isHosted"] && !isset($_GET['hideapi'])) {
        // Hosted version, show input field for the JSON API