|
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/kamariallee.com/public_html/application/views/ |
Upload File : |
<?php defined('BASEPATH') OR exit('No direct script access allowed'); ?>
<!-- Breadcrumbs -->
<div class="breadcrumbs">
<div class="container">
<div class="row">
<ul class="bcrumbs" id="crumbs">
<li><a href="<?= base_url(); ?>">Home</a></li>
<li style="color:white;"><?= $product->title; ?></li>
</ul>
</div>
</div>
</div>
<!-- End of Breadcrumbs -->
<div class="container">
<div class="row">
<!-- Site Content -->
<div class="col-md-12">
<p><br><?= $this->session->flashdata('no_stock'); ?></p>
<!-- Product List -->
<div class="product-list">
<div class="row">
<div class="product-single-col">
<div class="col-md-5 col-sm-4 product-slider">
<div class="product-img ">
<div class="detail-slider">
<ul class="slides">
<?php if ($product->image1 != NULL) : ?>
<li data-thumb="<?= base_url() . 'uploads/product/thumbnail/'. $product->image1; ?>">
<a title="<?= $product->title; ?>" style="cursor:zoom-in;" data-lightbox="image-1" href="<?= base_url() . 'uploads/product/' . $product->image1; ?>"><img src="<?= base_url() . 'uploads/product/large/'. $product->image1; ?>" alt="img-responsive" /></a>
</li>
<?php endif; ?>
<?php if ($product->image2 != NULL) : ?>
<li data-thumb="<?= base_url() . 'uploads/product/thumbnail/'. $product->image2; ?>">
<a title="<?= $product->title; ?>" style="cursor:zoom-in;" data-lightbox="image-2" href="<?= base_url() . 'uploads/product/' . $product->image2; ?>"><img src="<?= base_url() . 'uploads/product/large/'. $product->image2; ?>" alt="img-responsive" /></a>
</li>
<?php endif; ?>
<?php if ($product->image3 != NULL) : ?>
<li data-thumb="<?= base_url() . 'uploads/product/thumbnail/'. $product->image3; ?>">
<a title="<?= $product->title; ?>" style="cursor:zoom-in;" data-lightbox="image-3" href="<?= base_url() . 'uploads/product/' . $product->image3; ?>"><img src="<?= base_url() . 'uploads/product/large/'. $product->image3; ?>" alt="img-responsive" /></a>
</li>
<?php endif; ?>
<?php if ($product->image4 != NULL) : ?>
<li data-thumb="<?= base_url() . 'uploads/product/thumbnail/'. $product->image4; ?>">
<a title="<?= $product->title; ?>" style="cursor:zoom-in;" data-lightbox="image-4" href="<?= base_url() . 'uploads/product/' . $product->image4; ?>"><img src="<?= base_url() . 'uploads/product/large/'. $product->image4; ?>" alt="img-responsive" /></a>
</li>
<?php endif; ?>
<?php if ($product->image5 != NULL) : ?>
<li data-thumb="<?= base_url() . 'uploads/product/thumbnail/'. $product->image5; ?>">
<a title="<?= $product->title; ?>" style="cursor:zoom-in;" data-lightbox="image-5" href="<?= base_url() . 'uploads/product/' . $product->image5; ?>"><img src="<?= base_url() . 'uploads/product/large/'. $product->image5; ?>" alt="img-responsive" /></a>
</li>
<?php endif; ?>
</ul>
</div>
</div>
</div>
<div class="col-md-7 col-sm-8 product-details-single">
<div >
<h3 style="font-size:20px;" class="single-product-title"><a href="#"><?= strtoupper($product->title); ?></a></h3>
<?php if (count($review_ratings) != 0) : ?>
<div class="product-review-list pRviewListSingle ">
<ul>
<li>
<div class="star">
<?php for ($i = 0; $i < $average_rating; $i++) : ?>
<span class="yes"><i class="fa fa-star"></i></span>
<?php endfor; ?>
</div>
</li>
</ul>
</div>
<?php endif; ?>
<!-- <p><?= count($review_ratings); ?> reviews (s)</p> -->
<!-- <p><a style="color:black;" class="tulisReview" href="#" data-tab-destination="productReview">Add Your Review</a></p> -->
<script>
$(document).ready(function() {
$('a.tulisReview').click(function(event) {
event.preventDefault();
$('#reviewproduk a').addClass('active');
$('#infolengkap a').removeClass('active');
$('#det1').hide();
$('#det3').show();
$('html, body').animate({
scrollTop: $('#productReview').offset().top -210
}, 900);
});
});
</script>
<?php
$attributes = array(
'id' => 'formAddToCart',
);
?>
<?= form_open('cart/add', $attributes); ?>
<input type="hidden" name="product_id" value="<?= $product->id_products; ?>">
<input type="hidden" name="product_name" value="<?= $product->title; ?>">
<?php
//get the initial product price from stocks table
$this->db->select('price, discounted_price, sku, attributes')->from('product_details')->where('product_id', $product->id_products)/* ->where('stock !=' , 0)*/->order_by('id_product_details', 'ASC')->limit(1);
$prices = $this->db->get()->row();
$price = $prices->price;
$discounted_price = $prices->discounted_price;
?>
<?php
//check quantity discount if exist
$this->db->select('id_quantity_discount')->from('quantity_discount')->where('product_id', $product->id_products);
$count_quantity_discount = $this->db->get()->num_rows();
?>
<?php
//check if point rewards program is active or not.
$this->db->select('*')->from('point_rewards')->where('id_point_rewards', 1);
$point_rewards = $this->db->get()->row();
?>
<div class="shortDiscription">
<?= ucfirst($product->description); ?>
</div>
<br>
<?php if($count_quantity_discount > 0) : ?>
<div id="headingPrice" class="detail_top_desc_price clearfix">
<div class="detail_saleprice">Rp <?= number_format($price); ?></div>
<input type="hidden" name="price" value="<?= $price; ?>">
<?php if($point_rewards->active =='yes') : ?>
<?php
$point = $price / $point_rewards->ratio;
?>
<br><p>Get <strong><?= $point; ?></strong> Point Rewards by purchasing this product.</p>
<?php endif; ?>
</div><!-- end id="headingPrice" -->
<?php else : ?>
<div id="headingPrice" class="detail_top_desc_price clearfix">
<?php if ($discounted_price != 0): ?>
<div class="detail_saleprice">Rp <?= number_format($discounted_price); ?> <span class="det_oriprice" style="margin-left:20px;"><strike>Rp <?= number_format($price); ?></strike></span></div>
<div class="detail_top_desc_hemat" style="clear:both; font-size:12px;">You save Rp <?= number_format($price - $discounted_price); ?> </div>
<input type="hidden" name="price" value="<?= $discounted_price; ?>">
<?php if($point_rewards->active =='yes') : ?>
<?php
$point = $discounted_price / $point_rewards->ratio;
?>
<br><p>Get <strong><?= $point; ?></strong> Point Reward by purchasing this product.</p>
<?php endif; ?>
<?php else : ?>
<div class="detail_saleprice">Rp <?= number_format($price); ?></div>
<input type="hidden" name="price" value="<?= $price; ?>">
<?php if($point_rewards->active =='yes') : ?>
<?php
$point = $price / $point_rewards->ratio;
?>
<br><p>Get <strong><?= number_format(floor($point)); ?></strong> Point Rewards by purchasing this product.</p>
<?php endif; ?>
<?php endif; ?>
</div><!-- end id="headingPrice" -->
<?php endif; ?>
<?php if(count($product_links) > 0) : ?>
<p style="font-family:arial; font-size;14px;">Pilihan Warna Lain:</p>
<?php foreach($product_links as $link) : ?>
<?php
//get linked product alias, id and color_code
$this->db->select('title, alias, color_code')->from('products')->where('id_products', $link->link_to_product_id);
$product_link_atrributes = $this->db->get()->row();
?>
<a href="<?= base_url() . 'product/' . $product_link_atrributes->alias; ?>" title="<?= $product_link_atrributes->title; ?>"><span style="margin-right:10px; background-color:<?= $product_link_atrributes->color_code; ?>; width:25px; height:25px;float:left;"></span></a>
<?php endforeach; ?>
<br><br><br>
<?php endif; ?>
<br>
<?php if($count_product_stock > 0) : ?>
<div class="detail_top_addinfo">
<div class="detail_top_addinfo_label">Choose Product Option</div>
<div class="detail_top_addinfo_select">
<select required class="form-control" name="product_size" id="select_product_size" style="font-size: 13px; font-family: arial;">
<option value="">Select Size...</option>
<?php foreach ($product_details as $item) : ?>
<option value="<?= $item->id_product_details; ?>">
<?= strtoupper($item->attributes); ?>
</option>
<?php endforeach; ?>
</select>
</div>
</div>
<br>
<div class="add_to_cart clearfix">
<div class="add_to_cart_qty">
<select required name="qty" id="select_product_quantity" class="form-control" style="font-size: 13px; font-family: arial;">
<option value="">Select Quantity...</option>
<?php for ($i=1; $i <=10 ; $i++) : ?>
<option value="<?= $i; ?>"><?= $i; ?></option>
<?php endfor; ?>
</select>
</div>
<br>
<div class="add-to-cart-single cart-btn">
<input style="color:white !important; background:transparent; border:none; position:relative; top:10px;" id="addToCartButton" type="submit" value="ADD TO CART" >
</div>
<div class="btn-others-single">
<ul>
<li><a href="<?= base_url() . 'wishlist/add_wishlist/' . $product->id_products; ?>"><i class="fa fa-heart-o"></i></a></li>
<!-- <li><a href=""><i class="fa fa-exchange"></i></a></li> -->
</ul>
</div>
<script>
$(document).ready(function() {
$('#select_product_size').change(function() {
var id_product_details = $(this).val();
ajax_get_price(id_product_details);
});
var controller = 'ajax';
var base_url = '<?php echo base_url(); ?>';
function ajax_get_price(id_product_details) {
$.ajax({
'url' : '<?php echo base_url(); ?>' + 'ajax' + '/ajax_get_price',
'type' : 'POST',
'data' : {'id_product_details' : id_product_details},
'success' : function(result) {
var container = $('#headingPrice');
if (result) {
container.html(result);
};
}
});
}
}); /*----end document ready -----*/
</script>
</div>
<?php else : ?>
<p style="font-size:16px;">SOLD OUT</p>
<?php endif; ?>
</div>
<br><br>
<?= $product->long_description; ?>
<br>
<div class="addsharethisinner" style="margin-top: 10px; margin-bottom: 10px">
<span class="st_twitter_hcount sharebtn" displayText="Tweet"></span>
<span class="st_googleplus_hcount" displayText="Google +"></span>
<span class="st_pinterest_hcount sharebtn" displayText="Pinterest"></span>
<span class="st_facebook_hcount sharebtn" displayText="Facebook"></span>
</div>
<br>
<script type="text/javascript">/* <![CDATA[ */$(function(){$(".addsharethis").addClass("loader");$(window).load(function(){$(".addsharethis").removeClass("loader");$(".addsharethisinner").show(400);});});$(function(){$(".addsharethis .sharebtn").click(function(){$(this).find("img").show("medium");})});/* ]]> */</script><script type="text/javascript">/* <![CDATA[ */var switchTo5x=true;/* ]]> */</script><script type="text/javascript" src="http://w.sharethis.com/button/buttons.js">/* <![CDATA[ *//* ]]> */</script><script type="text/javascript">/* <![CDATA[ */stLight.options({publisher:"ea22d519-9f98-4018-99a9-5b5f1b100fa8",doNotHash:false,doNotCopy:false,hashAddressBar:false});/* ]]> */</script>
</div>
</div>
</div>
<!-- Product Single -->
<!-- Product Info Tab -->
<!-- <div class="row productINFOtab">
<div class="product-info-tab col-md-12">
<ul class="InfoTab" role="tablist" id="infoTab">
<li role="presentation" class="active"><a href="detail.html#discription" aria-controls="discription" role="tab" data-toggle="tab">DESCRIPTION</a></li>
<li role="presentation"><a href="detail.html#review" aria-controls="review" role="tab" data-toggle="tab">SPECIFICATION</a></li>
<li role="presentation"><a href="detail.html#tags" aria-controls="tags" role="tab" data-toggle="tab">REVIEW</a></li>
</ul>
<div class="tab-content">
<div role="tabpanel" class="tab-pane active" id="discription">
<div class="product-info-content">
</div>
</div>
<div role="tabpanel" class="tab-pane" id="review">
<div class="product-info-content">
</div>
</div>
<div role="tabpanel" class="tab-pane" id="tags">
<div class="product-info-content">
</div>
</div>
</div>
</div>
</div> -->
<!-- Product Info Tab -->
</div>
</div>
<!-- Site Content -->
</div>
</div>
<br> <br>
<!-- UPSELL PRODUCTS -->
<div class="upsell">
<div class="container">
<div class="row">
<div class="col-md-12 text-center">
<div class="section-title"><span>YOU MAY ALSO LIKE</span></div>
</div>
<?php
//get product on the same category
$this->db->select_max('id_category')->from('category_product')->where('id_product', $product->id_products);
$category_id = $this->db->get()->row()->id_category;
//select $products by given $category_id
$this->db->select('id_product')->from('category_product')->where('id_category', $category_id)->limit(4);
$products = $this->db->get()->result();
?>
<div class="hot-deal-products">
<?php foreach ($products as $product) : ?>
<?php
//get product detail
$this->db->select('id_products, title, alias, image1')->from('products')->where('id_products', $product->id_product)->where('product_status', '1')->order_by('id_product', 'RANDOM');
$related_product = $this->db->get()->row_array();
?>
<?php if(count($related_product) > 0) : ?>
<div class="col-md-3 col-sm-6">
<div class="product-singleArea">
<div class="product-img">
<a href="<?= base_url() . 'product/' . $related_product['alias']; ?>"><img src="<?= base_url() . 'uploads/product/small/' . $related_product['image1']; ?>" class="img-responsive pi-1" alt=""/></a>
</div>
<div class="product-details">
<div class="product-title"><a href="<?= base_url() . 'product/' . $related_product['alias']; ?>"><?= $related_product['title']; ?></a></div>
<!-- <div class="product-pd">
<div class="product-price">$50</div>
<div class="product-discount">-25%</div>
</div> -->
<!-- <div class="product-review">
<div class="star">
<span class="yes"><i class="fa fa-star"></i></span>
<span class="yes"><i class="fa fa-star"></i></span>
<span class="yes"><i class="fa fa-star"></i></span>
<span class="yes"><i class="fa fa-star"></i></span>
<span class="yes"><i class="fa fa-star"></i></span>
</div>
</div> -->
</div>
</div>
</div>
<?php endif; ?>
<?php endforeach; ?>
</div>
</div>
</div>
</div>
<!-- UPSELL PRODUCTS -->