Jump to content

Срочно нужна помощь в мониторинге

Featured Replies

Posted
comment_91214

Зарание благодарю за ответ.

У меня такая проблема: "Когда зашел на /lgsl/admin.php и добавляю сервер sa:mp меня перекидывает на окно авторизации и так каждый раз."

Вот такая ошибка когда зашел в /lgsl/admin.php - 

Warning: Cannot modify header information - headers already sent by (output started at /home/contine2/domains/continent-samp.su/public_html/forum/lgsl/lgsl_files/lgsl_config.php:1) in/home/contine2/domains/continent-samp.su/public_html/forum/lgsl/admin.php on line 20

Warning: Cannot modify header information - headers already sent by (output started at /home/contine2/domains/continent-samp.su/public_html/forum/lgsl/lgsl_files/lgsl_config.php:1) in/home/contine2/domains/continent-samp.su/public_html/forum/lgsl/admin.php on line 29

 
Путь указал правильно. Логин и Пароль тоже указал.
 
Вот мой admin.php - строка 29 - "это строка 29_______..."

<?php
//------------------------------------------------------------------------------------------------------------+
  require "lgsl_files/lgsl_config.php";


  if (empty($lgsl_config['admin']['user']) || empty($lgsl_config['admin']['pass']))
  {
    exit("ADMIN USERNAME OR PASSWORD MISSING FROM CONFIG");
  }
  elseif ($lgsl_config['admin']['pass'] == "changeme")
  {
    exit("ADMIN PASSWORD MUST BE CHANGED FROM THE DEFAULT");
  }

  $auth   = md5($_SERVER['REMOTE_ADDR'].md5($lgsl_config['admin']['user'].md5($lgsl_config['admin']['pass'])));
  $cookie = isset($_COOKIE['lgsl_admin_auth']) ? $_COOKIE['lgsl_admin_auth'] : "";

  if (isset($_POST['lgsl_user']) && isset($_POST['lgsl_pass']) && $lgsl_config['admin']['user'] == $_POST['lgsl_user'] && $lgsl_config['admin']['pass'] == $_POST['lgsl_pass'])
  {
    setcookie("lgsl_admin_auth", $auth, (time() + (60 * 60 * 24)), "/");
    define("LGSL_ADMIN", TRUE);
  }
  elseif ($cookie == $auth)
  {
    setcookie("lgsl_admin_auth", $auth, (time() + (60 * 60 * 24)), "/");
    define("LGSL_ADMIN", TRUE);
  }
это строка 29________________________________________________________________________________
  header("Content-Type:text/html; charset=utf-8");
//------------------------------------------------------------------------------------------------------------+
?>

 

<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.1//EN'


  <head>
    <title>Live Game Server List</title>
    <meta http-equiv='Content-Type' content='text/html; charset=utf-8' />
    <meta http-equiv='content-style-type' content='text/css' />
    <link rel='stylesheet' href='lgsl_style.css' type='text/css' />
  </head>

  <body>
    <div style='height:30px'><br /></div>

 


<?php
//------------------------------------------------------------------------------------------------------------+
  if (defined("LGSL_ADMIN"))
  {
    global $output;
    $output = "";
    require "lgsl_files/lgsl_admin.php";
    echo $output;
  }
  else
  {
    echo "
    <form method='post' action=''>
      <table style='margin:auto; text-align:center'>
        <tr><td> Логин: </td><td> <input type='text'     name='lgsl_user' value='' /> </td></tr>
        <tr><td> Пароль: </td><td> <input type='password' name='lgsl_pass' value='' /> </td></tr>
        <tr>
          <td colspan='2'>
            <br />
            <input type='submit' name='lgsl_admin_login' value='Login' />
          </td>
        </tr>
      </div>
    </form>
  }
//------------------------------------------------------------------------------------------------------------+
?>

 

  </body>
</html>

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.


Guest
Ответить в этой теме...

Последние посетители 0

  • No registered users viewing this page.