
<div id="content">
  <div id="inner">

  
 <div class="detailservice">

<center><h2 style="padding-left:150px;color:#cc0000;padding-bottom:20px">
<?php echo $result;?>
</h2>
</center>



<?php if($cart = $this->cart->contents()):?>



<table border="0" style="width:90%">
<caption style="color:#fff;background:#462D4F;font-weight:bold">Your Cart</caption>
<thead>
<tr style="background:#EBEBEB">
<th align="left" style="padding:5px;font-family:Arial;font-size:13px;color:#2C1C19;font-weight:bold">Item Name</th>
<th style="font-family:Arial;font-size:13px;color:#2C1C19;font-weight:bold">Price</th>
<th style="font-family:Arial;font-size:13px;color:#2C1C19;font-weight:bold">Qty</th>
<th style="font-family:Arial;font-size:13px;color:#2C1C19;font-weight:bold">Total</th>
<th style="font-family:Arial;font-size:13px;color:#2C1C19;font-weight:bold">Remove</th>
</tr>
</thead>
<?php $qty_num = 0; ?>
<?php $names_i = 0;$x=0; ?>
<?php foreach($cart as $item): $x++; ?>
    <tr style="background:#BCAEBF">
    <td style="padding:5px;font-family:Arial;font-size:12px;color:#2C1C19;font-weight:bold">
    <input name="id" value="<?php echo $item['id']; ?>" type="hidden" />
    <?php echo $item['name']; ?>
    </td>  
    <td align="center" style="font-family:Arial;font-size:12px;color:#2C1C19;font-weight:bold"><?php echo $item['price'] ; ?></td>
    <td align="center" style="font-family:Arial;font-size:12px;color:#2C1C19;font-weight:bold">
    <form method="post" name="frm<?php echo $x;?>" action="<?php echo base_url();?>temp/update">
     <input  type="hidden" name="rowid" value="<?php echo $item['rowid']; ?>"/>
    <input type="text" name="qty" style="width:35px" value="<?php echo $item['qty']; ?>"/><a alt="Refresh Cart" title="Refresh Cart" style="text-decoration:none;cursor: pointer;" onclick="frm<?php echo $x?>.submit()"> <img alt="Refresh Cart" title="Refresh Cart" src="<?php echo base_url()?>template/images/refresh.png" /></a>
    </form>
    </td>
    <td align="center" style="font-family:Arial;font-size:12px;color:#2C1C19;font-weight:bold">
    <?php echo $item['price'] * $item['qty']; ?>
    </td>
    <td class="remove" align="center"><a style="text-decoration:none;color:#fff;" href="<?php echo base_url()?>index.php/temp/remove/<?php echo $item['rowid']; ?>"  title="Remove from Cart">X</a></td>
    </tr> 
    <?php $qty_num += $item['qty']; ?>  
<?php endforeach;?>

<tr class="total" style="background:#462D4F">
<td style="color:#fff"><strong>Total</strong></td>
<td>

</td>
<td align="center"  style="color:#fff"><?php echo $qty_num; ?></td>
<td align="center" style="color:#fff">
<?php echo $this->cart->total(); ?>
</td>
<td></td>

</tr>
</table>
<form method="post" action="<?php echo base_url();?>temp/add_checkout">
<br class="clr">
<h2>Send Request</h2>
<center>
<input type="submit" class="send float-left" value="CHECKOUT"/></center>
<br class="clr">


</form>
<br class="clr">

&nbsp;


<?php else:
//redirect('products');

?>
<table border="0" style="width:70%">
<caption style="color:#fff;background:#462D4F;font-weight:bold">Your Cart Empty </caption>
</table>

<?php endif;?>


</div></div>
</div>