<section id="bookedroom"><legend><label id="min_label"><i>Order item from <?php echo $shop['shopname'];?></i></label></legend>
 <table>

     <form id ="checkout_form" action="shopPaymentPage.php" method="POST">

 <tr>
 	<td colspan="2">

 	  <i>Item name:-</i> <?php echo $ro['itemname'];?>
 	 	
 	</td>

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

 	 <i>Price/Item:-</i><<?php echo $ro['currency']." ".$ro['itemcost']; ?> <p/>

  

 Item Quantity:<?php echo $_POST['quantity'];?><br/>


   <i>Total:-</i><?php $itemTcost=$pi['price']*$_POST['quantity']; echo $pi['currency']." ".$itemTcost; ?> <p/>
 	
 </td>

 </tr>


<tr>

<td valign="top" colspan="2">

     <img src="<?php echo $ro['profileimages']; ?>" id="orderpic">
</td>

 


</tr>    


    <tr>

       <td colspan="2">

  
    <i>Item id:</i><?php echo $ro['itemid'];?>
        
        </td>

         
    
  </tr>

    
 

 



<!---- lllllljjjjjjjjjjjjjjjj 

 
  
CARRY SOME INFO

              -->
              <input class="hi" type="hidden" name="owniD"  value="<?php echo $ownID;?>"/>

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

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

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

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

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

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



         
 

   

  <tr >
 
        <td colspan="2">

           <i>Confirm payment by entering payment code here:-</i>

           <sup>*</sup><br><sup id="cd"></sup><p/>
       </td>
    </tr>
       <td  valign="bottom"> 
        <input type="text" name="code" id="code" class="prof_info" value="<?php echo $code;?>"  /><br/>
        
        </td>
        <td  valign="bottom"> 

        <input type="submit"  name="post" value="CheckOut Now" id="book"/>
   </td>
       
  </tr>


<!--- MMMMMMMMMMMMM  -->


 
 </table>
 
</form>
 </table>
	
</section>
<label id="main_label"> <?php echo $shop['shopname'];?> </label>
<table border="0" width="45%">
   <tr>
  <td>
<ul>
  <li style="padding-right:3%;">
    <form id="order" action="buda_shoping_center.php" method="post">

                      <input   type="hidden" name="owniD" id="owniD" value="<?php  echo $ownID;?>">

                       
                      <input  class="spos" type="submit" value="My shop" name="post"> 

                 </form>  
     
  </li>
<li style="padding-right:50%;">
   <form id="order" action="defaultShopingCenterInOther.php" method="post">

                      <input   type="hidden" name="owniD"  value="<?php  echo $ownID;?>">

                       
                      <input  class="spos" type="submit" value="Other shop" name="post"> 

                 </form> 
</li>
 
<li>
 <form id="order" action="itemViewInOther.php" method="post">

                      <input   type="hidden" name="owniD"  value="<?php  echo $ownID;?>">

                       
                      <input  class="spos" type="submit" value="Item view" name="post"> 

                 </form>   
 </li>
</ul>
</td>
</tr>
  
</table>
<fieldset id="payOption"><legend><label id="main_label"><i>Choose the appropriate payment method and then follow  the steps:-</i></legend>
<b> Pay total amount of:<?php echo $ro['currency']." ".$itemTcost;?></b><p/>
<b>For payment through Vodacam M-pesa:-</b><br>

	<ol>
		<li>
			Dial *150*00#
		</li>
		<li>
			
            Select Option 4 pay through M-pesa.
		</li>
		<li>
			Select Option 4 company number.
		</li>
		<li>
			Select Option 4 company payment reference number.
		</li>
	</ol>

	<b>For payment through Airtel Money:-</b><br>

	<ol>
		<li>
			Dial *150*60#
		</li>
		<li>
			
            Select Option 4 pay through M-pesa.
		</li>
		<li>
			Select Option 4 company number.
		</li>
		<li>
			Select Option 4 company payment reference number.
		</li>
	</ol>

	<b>For payment through Tigo Pesa:-</b><br>

	<ol>
		<li>
			Dial *150*01#
		</li>
		<li>
			
            Select Option 4 pay through M-pesa.
		</li>
		<li>
			Select Option 4 company number.
		</li>
		<li>
			Select Option 4 company payment reference number.
		</li>
	</ol>
</fieldset>
 
<script type="text/javascript">
$("#checkout_form").on('submit',function(e){
 
  


var code=document.getElementById('code').value;
 
var nN =/[A-Z0-9]/i;
var j=0,k=0, g=0,i=0;

//////////////////
/////////////////////             REGISTRATION   //////////////////
          //////////////////////////////////

  

///////////////////////////////////  H

 if(code==""){
  e.preventDefault();

document.getElementById('cd').innerHTML="Payment code to required!..";

 }
 else{

      for(i=0;i<code.length;i++)
       {
         if(!code[i].match(nN))
          {
             j++;

           }
        }
      
       if(j>0){
       e.preventDefault();
   
        document.getElementById('cd').innerHTML="Payment code to typed with error!.."; 
              }
         else{
 
        document.getElementById('cd').innerHTML="";

              }
   }
 
    j=0, i=0;
  

     ////////////mmm
  
}
);
   
</script>
