Server : Apache/2.4.18 (Ubuntu) System : Linux canvaswebdesign 3.13.0-71-generic #114-Ubuntu SMP Tue Dec 1 02:34:22 UTC 2015 x86_64 User : oppastar ( 1041) PHP Version : 7.0.33-0ubuntu0.16.04.15 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority, Directory : /var/www/blue-sky.co.id/public_html/application/modules/cart_widget/views/ |
Upload File : |
<div class="shopping-cart floatright"> <a title="View your shopping cart" href="<?= base_url('cart'); ?>" class="cart-contents"> <?php //count cart items $count_cart = count($this->cart->contents()); ?> <span class="cart-number tombol"><?= $count_cart; ?> <?= lang('items'); ?></span> </a> <style type="text/css"> .menu{ position: fixed; background: #f6f6f6; color: #232323; /*max-height: auto;*/ width: 210px; top: 0; right: -300px; -webkit-transition: right 0.2s; transition: right 0.2s; padding: 10px; z-index: 1000; } #scroll{ width: 209px; max-height: 350px; overflow :auto; /*overflow-x :hien;*/ } .menu ul{ padding: 0; } .menu li{ list-style-type: none; padding: 10px 0px; } .tombol{ cursor: pointer; } .slide-menu-tampil{ right: 0 !important; } </style> </div> <nav class="menu"> <div class="row" > <?php if ($cart = $this->cart->contents()): ?> <div id="scroll"> <?= form_open('cart/update_cart'); $grand_total = 0; foreach ($cart as $item): echo form_hidden('cart_array['. $item['options']['sku'] .'][id]', $item['id']); echo form_hidden('cart_array['. $item['options']['sku'] .'][rowid]', $item['rowid']); echo form_hidden('cart_array['. $item['options']['sku'] .'][name]', $item['name']); echo form_hidden('cart_array['. $item['options']['sku'] .'][price]', $item['price']); echo form_hidden('cart_array['. $item['options']['sku'] .'][qty]', $item['qty']); echo form_hidden('cart_array['. $item['options']['sku'] .'][options][size]', $item['options']['size']); echo form_hidden('cart_array['. $item['options']['sku'] .'][options][sku]', $item['options']['sku']); ?> <?php //get product image $image_thumb = $this->product_m->get_image($item['id']); ?> <?php //get product alias $this->db->select('alias')->from('products')->where('id_products', $item['id']); $product_alias = $this->db->get()->row()->alias; ?> <div class="col-sm-6" style="margin-top: 10px;"> <img style="width: 100%" src="<?= base_url('uploads/product/thumbnail') .'/'. $image_thumb->image1; ?>" /> </div> <div class="col-sm-6" style="margin-left: -20px; padding-right: 1px !important"> <div style="text-align: right;"> <a href="<?= base_url('cart/removes') . '/' . $item['rowid']; ?>" style="color:black; background: none; position:relative; top: 15px;">X</a> </div> <div style="font-size: 10px; "> <p>Rp <?php echo number_format($item['price']); ?></p> <p>Qty :<?= $item['qty']; ?></p> <?php $grand_total = $grand_total + $item['subtotal']; ?> <p>Total :<br>Rp <?php echo number_format($item['subtotal']); ?></p> </div> </div> <div class="col-sm-12" style="font-size: 10px"> <p ><?php echo strtoupper($item['name']); ?></p> </div> <?php endforeach; ?> </div> <div class="col-sm-12"> <hr> <?php //check if PPN 10% is active $this->db->select('ppn_active')->from('configuration')->where('id_configuration', 1); $ppn_active = $this->db->get()->row()->ppn_active; ?> <?php if($ppn_active == 'yes') : ?> <?php $ppn_amount = $grand_total * 10/100; $grand_total = $grand_total + $ppn_amount; ?> <p>Tax 10% : IDR <?php echo number_format($ppn_amount); ?></p> <?php endif; ?> <p style="font-weight: bold;">TOTAL : IDR <?php echo number_format($grand_total); ?></p> </div> <?php else: ?> <div class="col-sm-12" style="text-align: center;"> <p>Cart Empty</p> </div> <?php endif; ?> </div> <div class="row"> <div class="col-sm-12"> <form action="<?= base_url('cart'); ?>"> <button class="btn" style="width: 100%; padding: 5px; margin-bottom: 10px">Chekout</button> </form> </div> <div class="col-sm-12"> <button class="btn tombol" style="width: 100%; padding: 5px;">Continue Shopping</button> </div> </div> </nav> <script type="text/javascript"> $(document).ready(function(){ <?php if($this->session->flashdata('after_addcart') == TRUE) : ?> $('.menu').addClass("slide-menu-tampil"); <?php endif; ?> /* $('.tombol').click(function(){ $('.menu').toggleClass("slide-menu-tampil"); }); */ }); </script> <!-- SHOPPING CART -->