 

<?php
 require_once("headUserAcc.php");
?>

<table width="100%">
<tr><td colspan="2"><b> HEXA<font size="6">N</font>DEAL </label> </b></td></tr>
 
</table>
 
<?php
if(isset($_POST['post'])){ 
        $HD=$xcon->getHexaNdealPostOut(); 
    
        if($HD->rowCount()>0){
          $ro=$HD->fetchAll();
         
?>
<center>

<table   class ="roomtab">
    
    
     <tr>
      
    <td>
    <center>

    <table border="0" class ="roomtab">

               <tr><td colspan="7" > </td>

               <td align="right" colspan="4">
       <ul>
         <li>
             <form action="hexaNdeal.php" method="post">
 
 

                              <input class="hi" type="hidden" name="admin"  value="<?php echo $admin;?>">

                              <input class="pos" type="submit" value="Deal post" name="post"  >
               </form>
         </li>
          <li style="padding-right:5%;">
             <form action="needPost.php" method="post">
 
 

                              <input class="hi" type="hidden" name="admin"  value="<?php echo $admin;?>">

                              <input class="pos" type="submit" value="Need post" name="post"  >
               </form>
         </li>
       </ul>
                          
                        
               </td>

               </tr>             

                <tr class="tr1">
                <td id="td_height" ><label id="inner_top">TITLE</label></td> <td id="td_height" ><label id="inner_top">POST BY</label></td>
                <td id="td_height" ><label id="inner_top">CATEGORY</label></td> 
                <td><label id="inner_top">VALUE</label></td><td><label id="inner_top">STATUS</label></td>
 
                <td id="td_height" ><label id="inner_top">PHONE NUMBER</label></td><td><label id="inner_top">PERSON TO CONTACT</label></td><td><label id="inner_top">POSTED ON</label></td><td><label id="inner_top">DEADLINE</label></td>
                <td><label id="inner_top">POSTAL ADDRESS</label></td><td><label id="inner_top">DESCRIPTION</label></td>

                </tr>

        <?php foreach ($ro as $key => $row) {
          $current="current";
         // $hnm=$row['hotel_id'];
          $ownID=$row['advertiserid'];
          $WN=$con->getMyProfile($ownID)->fetch();
    
 
 



        ?>


       <tr class="tr2">
          <td   align="left" valign="top">  

              
                 <form action="../hexaNdeal/myDealPostDetail.php" method="post">

                     <input class="hi" type="hidden" name="owniD"  value="<?php echo $row["advertiserid"];?>">


                     <input class="hi" type="hidden" name="dealid"  value="<?php echo $row["dealid"];?>">

                    <input  class="pos" type="submit" value="<?php echo $row["title"];?>" name="post">

                 </form>

                 
              </td>
              <td id="td_height" ><label id="inner_lab"> <?php echo $WN["fname"]." ".$WN["mname"]." ".$WN["lname"];?> </label></td>
                <td id="td_height" ><label id="inner_lab"> <?php echo $row["category"];?> </label></td>
                

               <td id="td_height" ><label id="inner_lab"><?php echo $row["currency"].":".$row["cvalue"];?> </label></td><td><label id="inner_lab"><?php echo $row["status"];?> </label></td>

               <td id="td_height" ><label id="inner_lab"><?php echo $row["cphone"];?> </label></td><td><label id="inner_lab"><?php echo $row["cperson"];?> </label></td>
              <td><label id="inner_lab"><?php echo $row["posteddate"];?> </label></td>
               <td><label id="inner_lab"><?php echo $row["addeadline"];?> </label></td><td><label id="inner_lab"><?php echo $row["locationaddress"];?> </label></td><td><label id="inner_lab"><?php echo $row["description"];?> </label></td>
 
               </tr>    
      
 
<?php
}
?>
</table></center>
 <?php   

}else{
  ?>
  <center>
     <table class ="roomtab">
    
           

          <tr class="tr2">
            <td colspan="2"><label id="min_lab">Currently no registered shop!..</label></td>
          </tr>

     </table>
  </center>

     <?php

 }
}
 
?>

 
<script>

  function submision(){
    
    var searchValue=$('#searchValue').val();
    $('#result').empty();
    $.post('searchItemOut.php',{searchValue:searchValue},function(data){
      $('#result').html(data);

    });
  }
/* 
$(document).ready(function(){
  
$('#search').keyup(function(){
  var searchValue= $('#search').val();
  $trim(searchValue); 
  if (searchValue!='') {
    $.ajax({
      url:"searchItemOut.php",
      method:"POST",
      data:{searchValue:searchValue},
      success:function(data){
        $('#result').html(data);
      }
    });

  }
});
});*/
</script>