<div dir="rtl">
  <?php

  include("header.php");
  if (isset($_SESSION["state_login"]) && $_SESSION["state_login"] === true) {

    $link = mysqli_connect("localhost", "root", "", "shop-moble");
    if (mysqli_connect_errno())
      exit("این خطا رخ داده است" . mysqli_connect_error());

    $mbl_cod = 0;
    if (isset($_GET['id']))
      $mbl_cod = $_GET['id'];
    $query = "SELECT * FROM mbl WHERE mbl_cod='$mbl_cod'";

    $mobl1 = mysqli_query($link, $query);

    $mobl = mysqli_fetch_array($mobl1);




    $cod_meli = 0;
    if (isset($_SESSION['cod_meli']))
      $cod_meli = $_SESSION['cod_meli'];


    $query1 = "SELECT * FROM user WHERE cod_meli='$cod_meli'";
    $user = mysqli_query($link, $query1);

    $user1 = mysqli_fetch_array($user);




  ?>





    <form method="post" action="action-order.php" enctype="multipart/form-data">


      <div style="text-align: right; background-color: cadetblue" dir="rtl">



        <p>&nbsp;</p>
        <p>&nbsp;</p>
        <p>&nbsp;</p>
        <table style="background-color: gold" width="60%" border="1" align="center" cellspacing="2">
          <tbody>
            <tr>
              <td>فاکتور</td>
            </tr>

            <div style="background-color: aliceblue;  width= 950" align="center">



              <table style="float: left" width="302" border="0" cellspacing="2">
                <tbody>
                  <tr>
                    <td width="23" height="39">&nbsp;</td>
                    <td width="63">&nbsp;</td>
                    <td width="43">&nbsp;</td>
                    <td width="145">&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td height="48">&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td height="186" colspan="4"><img id="mbl_img" name="mbl_img" src="img/<?php echo ($mobl['mbl_img']); ?>" width="376" height="291">
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td height="23">&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                    <td colspan="3" rowspan="7">&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td height="23">&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                </tbody>
              </table>
              <p>&nbsp;</p>
              <p> کد ملی :
                <input name="cod_meli" type="text" id="cod_meli" max="10" min="10" value="<?php echo ($user1['cod_meli']); ?>">
                &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p> نام واقعی :
                <input name="name" type="text" id="name" value="<?php echo ($user1['name']); ?>" size="30">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <hr width=" 400" size="12" align="right" color="hsla(112,89%,50%,1.00)">
              <p>کد مبل :
                <input name="mbl_cod" type="text" id="mbl_cod" max="10" min="10" value="<?php echo ($mobl['mbl_cod']); ?>" readonly>&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p> نام مبل :
                <input name="mbl_name" type="text" id="mbl_name" value="<?php echo ($mobl['mbl_name']); ?>" size="20" readonly>&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <hr width=" 400" size="12" align="right" color="hsla(65,100%,50%,1.00)">
              </p>
              <p>کار :
                <input name="mbl_select_canteri" type="text" id="mbl_select_canteri" value="<?php echo ($mobl['mbl_select_cantre']); ?>" size="30" readonly>&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>چند نفره
                :
                <input name="mbl_select_nafar" type="text" id="mbl_select_nafar" placeholder=" 8 نفره . 10 نفره . 12 نفره " size="40">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>به چه صورت :
                <input name="mbl_action_nafar" type="text" id="mbl_action_nafar" placeholder="یه 2 نفره با 3 تا تک نفره " size="60">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>طرح و رنگ به چه صورت :
                <input name="mbl_select_rang" type="text" id="mbl_select_rang" size="60">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>جنس مبل :
                <select name="jens" id="jens">
                  <option>dddddd</option>
                  <option>ssssss</option>
                  <option>sffsf</option>
                  <option>sfsfef</option>
                </select>
                &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>چند سال ضمانت :
                <input name="mbl_select_years" type="text" id="mbl_select_years" value="پس از بررسی اعلام می گردد" size="40" readonly>&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <hr width=" 400" size="12" align="right" color="hsla(310,100%,51%,1.00)">
              شماره تلفن همراه:
              <input name="tel" type="tel" id="tel" value="<?php echo ($user1['tel']); ?>">
              &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              <p>ایمیل :
                <input name="email" type="email" id="email" value="<?php echo ($user1['emil']); ?>">&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <p>آدرس ارسال مبل :
                <textarea name="addres" cols="40" rows="6" id="addres"></textarea>
                &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <hr width=" 400" size="12" align="right" color="hsla(179,100%,49%,1.00)">
              <p>قیمت مبل :
                <input name="mbl_price" type="text" id="textfield8" value="پس از بررسی اعلام می گردد" size="40" readonly>&nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;
              </p>
              <hr width=" 400" size="12" align="right" color="hsla(112,89%,50%,1.00)">
              <p>
                <input type="submit" name="button" id="button" value="خرید">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <input type="reset" name="button2" id="button2" value="پاک کردن">
              </p>
            </div>
            <p>&nbsp;</p>
            <p>&nbsp;</p>
            <p>&nbsp;</p>
            <p>&nbsp;</p>
            <p>&nbsp;</p>
          <?php
        } else
          echo ("برای ورود به این قسمت از سایت باید در سایت عضویت داشته باشید.");
          ?>
    </form>
</div>

</div>