<?php
  ///////////////////////////////////////////////////
  //Вернуть книгу
  //2010 (C)
  //Карпухин Павел
  ///////////////////////////////////////////////////

 require_once "utils/chlang_osn.php";

  $title = $TEXT['book-nal-tit2'];
  $button = $TEXT['book-nal'];
  $action = "nal_on.php";

  require_once "config_a.php";
  require_once "utils/functions.php";
  require_once "utils/top.php";

  if($result2['administrator'] == 0) {puterror2($result2['skin'],$TEXT['error-loginform2']); require_once "utils/bottom.php"; exit();}

  if(empty($_GET['book_id'])) {puterror2($result2['skin'],$TEXT['error-book5']); require_once "utils/bottom.php"; exit();}
  if(strlen($_GET['book_id'])>20) {puterror2($result2['skin'],$TEXT['error-book6']); require_once "utils/bottom.php"; exit();}
  $_GET['book_id'] = rep($_GET['book_id']);

?>
<form enctype="multipart/form-data" action="<?php echo $action; ?>" method="post">
<table align="center" >
<tr><td class="bold_it"><?php echo $TEXT['menu-btn26-title']; ?></td><td>
    <select name="obr_id">
    <?php
        $query10 = "SELECT * FROM `tbl_obraschenie` ORDER BY `obr_id` ";
          $result10 = mysqli_query($dbcnx,$query10);
            if (!$result10) {puterror2($result2['skin'],$TEXT['error-tbl18']); require_once "utils/bottom.php"; exit();}
              while($result_obr = mysqli_fetch_array($result10))
                {
                 $chk_obr = "<option value=".$result_obr['obr_id'].">".$result_obr['kachestvo']."";
                 echo $chk_obr;
                }
    ?>
    </select></td></tr>
<tr><td></td><td><input class="button2" type="submit" value="<?php echo $button; ?>" />
<input type="hidden" name="book_id" value="<?php echo $_GET['book_id']; ?>" />
</td></tr>
</table>
</form>
<?php
  require_once "utils/bottom.php";
?>