
<form id="" action="" method="POST" enctype="multipart/form-data" autocomplete="off">
 <div class="row">
    <div class="col-md-10" style="background-image: url(../img/placeholders/inner-texture-bg.png); border-radius: 8px;">
      <div style='border-radius: 8px;border: 2px solid #7E9350;width:100%;margin-top:1%;margin-bottom:1%;'>
        <br/>
        <center>
           <b style="font-family: century gothic;font-size: 23px;"><i class="fa fa-info-circle"></i> Item Category.</b>
        </center>
        <br/>
        
        <div class="row">
        <div class="col-md-1"></div>
            <label class="col-form-label col-3 col-lg-3 form-label text-lg-right">Element<span class="required" style="color:red">*</span></label>
            <div class="col-sm-6">
                <select class="select2 form-control w-100" name="elem" id="elem" data-placeholder="-select element-" required>
                    <option></option>

                    <?php
                    $stmt = $db->query('SELECT *FROM tbl_elements');
                    try
                    {
                      while ($rrr = $stmt->fetch(PDO::FETCH_ASSOC)){
                    ?>
                      <option value="<?php echo $rrr['elemid'];?>"><?php echo $rrr['elemName'];?></option>
                    <?php
                        }
                        }
                        catch (PDOException $ex) {
                        //Something went wrong rollback!
                        echo $ex->getMessage();
                    }
                    ?>	
                </select>
            </div>
        </div>
        <br>

        <div class="row">
        <div class="col-md-1"></div>
            <label class="col-form-label col-3 col-lg-3 form-label text-lg-right">Category<span class="required" style="color:red">*</span></label>
            <div class="col-sm-6">
            <textarea type="text" name="ctgName" rows="2" class="form-control" placeholder="Write here..." required></textarea>
            </div>
        </div>
        <br>
        
        <div class="row">
          <div class="col-md-1"></div>
            <label class="col-form-label col-3 col-lg-3 form-label text-lg-right">Description</label>
            <div class="col-sm-6">
            <textarea type="text" name="ctgDesc" rows="2" class="form-control" placeholder="description here..."></textarea>
            </div>
        </div>
        <br>
        
        <hr>
        <center>
            <button type="reset" class="btn btn-default btn-sm" style="border-radius: 4px;">Reset</button>
            <button class="btn btn-primary btn-sm" name="btnCtg" style="border-radius: 4px;" type="submit" id="">Save</button>
        </center>
         <br>
    </div> <!--border -->
    </div>
  </div>
</form>