PHP:
скопировать код в буфер обмена
скопировать код в буфер обмена
- <?PHP
- {
- $user = $_POST['user'];
- $_SESSION['user'] = $_POST['user'];
- }
- {
- $pass = $_POST['pass'];
- $_SESSION['pass'] = $_POST['pass'];
- }
- {
- $id = $_POST['id'];
- $_SESSION['id'] = $_POST['id'];
- }
- $username = "51";
- $password = 1;
- if ($username==$user && $password==$pass)
- {
- echo "<p>Добро пожаловать!<a href='http://xxx.net/ty/1ndex.php'>Выйти</a></p>";
- }
- else
- {
- print <<<HERE
- <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection">
- <link rel="stylesheet" href="css/style.css" type="text/css" media="screen, projection">
- <link rel="stylesheet" href="css/print.css" type="text/css" media="print">
- <title>Вход</title>
- <body>
- <table width="200" border="0" align="center" cellpadding="0" cellspacing="0">
- <tr>
- <th scope="row"> </th>
- </tr>
- <tr>
- <th scope="row">
- <div valign="center" class='enter'><p align='center'><strong>Барановический городской РЭС</strong>
- <form action="index.php" method="post" name="form1">
- <p align="center">
- <label>Введите логин: <input name="user" type="text" id="user"/>
- </label>
- <label>Введите пароль: <input name="pass" type="text" id="pass"/>
- </label>
- <p align='center'>
- <input name="id" type="hidden" value="$row_aut[id]" />
- <input class="myButton" name="submit" type="submit" value="Войти" />
- </p>
- </p>
- </form>
- </div>
- </th>
- </tr>
- </table>
- </body>
- HERE;
- }
- ?>