<link rel="stylesheet" type="text/css" href="catalog/template/beststoreitems/css/new_product.css">
<script type="text/javascript" src="catalog/javascript/thickbox/thickbox-compressed.js"></script>
<!--<script type="text/javascript" src="catalog/javascript/jquery-1.3.2.min.js"></script><script type="text/javascript" src="catalog/javascript/pshow2.js"></script>-->
<script type="text/javascript" src="catalog/javascript/livequery.js"></script>
<script type="text/javascript" src="catalog/javascript/cart_number.js"></script>
<link rel="stylesheet" type="text/css" href="catalog/javascript/thickbox/thickbox.css" />
	 <div class="main container">
            <div class="product-essential-wrap clearfix" id="product">
                <div class="product-essential">
                    <div class="row product-content">
                        <!--product left-->
                        <div class="product-img-box col-sm-8 clearfix" id="preview">
                            <div class="product-main-slider" id="responsive-slider">
                            	<?php  if ($popup_images) { ?>
                                <div class="slider-main" id="slider_pic">
                                        <ul>
                                            <?php foreach ($popup_images as $f_image) { ?>
                                            <li><a href="javascript:;"><img class="sliderimg" src="<?php echo $f_image; ?>"/></a></li>
                                            <?php }?>
                                        </ul>
                                </div>
                                <?php }?>
                                <?php  if ($thumb_images) { ?>
                                <div class="min_pwic">
                                	<div class="arrows">
                                    	<div id="prev_btn1"><a class="previous"></a></div>
                                        <div id="next_btn1"><a class="next"></a></div>
                                    </div>
                                    <div class="thumbnail-scroller clearfix" id="ban_num1">
                                        <ul class="thumbnails-visible-container">
                                        	<?php foreach ($thumb_images as $f_image) { ?>
                                            	<li class="thumbnail-wrapper"><a href="javascript:;"><img src="<?php echo $f_image; ?>" width="56" height="56" alt=""/></a></li>
                                            <?php }?>
                                        </ul>
                                    </div>
                                </div>
                                <?php }?>
                            </div>
                        </div>
                        <!--product left end-->
                        <!--product center-->
                        <div class="col-md-11 col-sm-16 middle-col">
                          <h1 class="product-title"><?php echo $product_name; ?></h1>

                          <div class="product-info clearfix">
                            <div class="product-sku">
                                <span class="sku-nr">ITEM #<?php echo $product_id; ?></span><br>
                                <b class="availability">In Stock</b>&nbsp;<label style="color:green;">(<?php echo $quantity; ?>)</label>
                            </div>
                            <div class="product-reviews">
                                <i class="icon-sold"></i><span><?php echo $sold;?>&nbsp;<?php echo $sold<=1?'pc':'pcs'?></span>
                            </div>
                            <div class="product-votes">
                                <div class="rating">
                                    <span class="nostar">
                                        <span style="width:100%;" class="nstar"></span>
                                    </span>
                                </div>
                                <a href="/index.php?controller=product&product_id=123#pr-reviews" onclick="showReviews();"><b><?php echo $review_total?></b> <?php echo $review_total<=1?'Review':'Reviews'?></a>
                            </div>
                          </div>
                          <div class="price-box clearfix  xl">
                              <div class="old-price"><?php echo $market_price; ?></div>
                              <div class="regular-price"><?php echo $price; ?></div>
                              <div class="notice-link">
                                    <a class="discount-btn" href="">
                                    <span>Take up to</span><br>
                                    <span>40% off</span></a>
                               </div>
                          </div>
                          <table class="tier-prices product-pricing">
                                    <tbody>
                                        <tr>
                                            <td colspan="5">Bulk Order Discount</td>
                                        </tr>
                                        <tr>
                                            <td>Qty.Range(unit)</td>
                                            <td>2-10</td>
                                            <td>11-20</td>
                                            <td>21-above</td>
                                            <td>Dropship Price</td>
                                        </tr>
                                        <tr>
                                            <td>Price(per unit)</td>
                                            <td>$4.01</td>
                                            <td>$3.91</td>
                                            <td>$3.80</td>
                                            <td>$3.76</td>
                                        </tr>
                                    </tbody>
                            </table>
                          <form action="index.php?controller=product&product_id=<?php echo $product_id; ?>" method="post" enctype="multipart/form-data">
                          <?php if ($options) { ?>
                          <div class="options_box clearfix">
                            <?php foreach ($options as $option) { ?>
                              <dl class="options_menu">
                                  <dt><?php echo $option['name']; ?>:</dt>
                                  <dd>
                                      <select name="option[<?php echo $option['option_id']; ?>]" id="option<?php echo $option['option_id']; ?>" style="color:red;" class="selectMian">
                                        <option value=""></option>
                                          <?php foreach ($option['value'] as $option_value) { ?>
                                        <option value="<?php echo $option_value['product_to_option_id']; ?>"><?php echo $option_value['name']; ?>
                                            <?php if ($option_value['price']) { ?>
                                            <?php echo $option_value['prefix']; ?><?php echo $option_value['price']; ?>
                                            <?php } ?>
                                        </option>
                                        <?php } ?>
                                      </select>
                                  </dd>
                              </dl>
                              <?php } ?>
                          </div>
                          <?php }?>
                          <div class="product-options-bottom">
                                  <div class="add-to-cart clearfix">
                                      <label>Quantity</label>
                                      <div class="input-group qty-group">
                                        <button type="button" class="btn minus btn-gray" id="itemjian">-</button><input type="text" name="quantity" id="quantity" value="1" qty="1" warecode="" kitorder="0" class="input-text qty form-control"/><button type="button" class="btn plus btn-gray" id="itemjia">+</button>
                                     </div>
                                     <?php if ($quantity<=0 || $status==0) {?>
                                          <button type="button" class="btn btn-primary btn-cart" onclick="javascript:showWant()">I Want to order</button>
                                      <?php }else{?>
                                          <input type="submit" class="btn btn-primary btn-cart" id="addtocart" value="Add to Cart">
                                      <?php }?>
                                  </div>
                          </div>
                          </form>
                          <ul class="add-to-links">
 <li><a id="link-wishlist" class="link-wishlist"  href="javascript:void(0);"><i class="icon-heart"></i> Add to Wishlist</a></li>
                          </ul>
                          <!--add to cart-->
                          <div id="atc-box">
                              <div class="atc-inner">
                                  <a href="javascript:void(0);" class="atc-close" id="atc-close-btn"></a>
                                  <div class="clearfix">
                                      <div class="atc-caption">
                                          <i class="icon_success"></i>
                                          New item added to cart
                                      </div>
<div class="atc-message-success"><em id="shopping_cart_num">0</em> total items in your Cart, Cart Total: <span id="shopping_cart_total" class="price"><?php echo $cart_total; ?></span></div>
                                      <div class="atc-actions">
                                          <a href="javascript:void(0);" class="btn btn-dark-gray" id="continue_shopping_btn">Continue Shopping</a>
                                          <a href="/index.php?controller=cart" class="btn btn-primary">View Cart & Checkout</a>
                                          <div style="clear: both;"></div>
                                      </div>
                                  </div>
                              </div>
                          </div>
                          <!--add to cart end-->

						  <!--add to wish-->
                          <div id="wishlist">
                              <?php if($customer_logged) { ?>
    								<div class="atc-inner">
                                      <a href="javascript:void(0);" class="atc-close" id="wishlist-close-btn"></a>
                                      <div class="clearfix">
                                          <div class="atc-caption">
                                              <i class="icon_success"></i>
                                              New item added to wishlist
                                          </div>
    <div class="atc-message-success"><em id="wishlist_count">0</em> total items in your wishlist</div>
                                          <div class="atc-actions">
                                              <a href="javascript:void(0);" class="btn btn-dark-gray" id="continue_shopping_btn_wish">Continue Shopping</a>
                                              <a href="/index.php?controller=my_wishlist" class="btn btn-primary">View Wishlist</a>
                                              <div style="clear: both;"></div>
                                          </div>
                                      </div>
                                  </div>
                              <?php }else{ ?>
                                <div class="atc-inner atc-inner-login">
                                	<h2>Sign In</h2>
                                	<a href="javascript:void(0);" class="atc-close" id="wishlist-close-btn"></a>
                                    <div class="clearfix">
    									<form enctype="multipart/form-data" method="post" action="index.php?controller=account_login" id="xsignIn">
                                            <div id="login-form-part">
                                                <ul>
                                                    <li class="form-group">
                                                        <input placeholder="Email Address" size="25" id="loginName" maxlength="128" name="email" value="" tabindex="1" class="input-text form-control">
                                                    </li>
                                                    <li class="form-group">
                                                        <input type="password" placeholder="Password" size="25" id="loginPassword" name="password" maxlength="100" value="" tabindex="2" class="input-text form-control">
                                                    </li>
                                                </ul>
                                                <div class="form-group forgetpw"><a id="forgotPwId" href="https://www.beststoreitems.com/index.php?controller=account_forgotten">Forgot password?</a></div>
                                                <div class="buttonWrap">
                                                    <input type="submit" onclick="return login_checkinput();" value="Sign &nbsp;in" id="submitName" class="btn btn-primary">
                                                </div>
                                          </div>
                                        </form>
                                    </div>

                                </div>
                              <?php } ?>
                          </div>
                          <!--add to wish end-->
                      </div>
                      <!--product center end-->

                      <!--product right-->
                      <div class="col-md-5 hidden-sm hidden-xs product_benefits_bg right"></div>
                      <div class="col-md-5 hidden-sm product_benefits_col">
                          <div class="product-benefits">
                              <div class="pr-benefit">
                                  <span class="benefit-icon"><i class="icon-truck"></i></span>
                                  <span class="benefit-title">Delivery Guaranteed</span>
                              </div>
                              <div class="pr-shipp">
                                  <span class="pr-shipp-title">Fast and easy shipping</span>
                                  <span class="pr-shipp-info">We provide a hassle free shipping process for all items
                                  </span>
                              </div>
                              <div class="row">
                                <div class="col-xs-12 benefit-half first">
                                    <div class="pr-benefit ttip">
                                        <span class="benefit-icon">
                                            <i class="icon-badge"></i>
                                        </span>
                                        <span class="benefit-title">
                                            Money Back Guarantee
                                            <span class="ttip-info">We provide a 100% money back guarantee if you are not satisfied with your purchase. We will provide a full refund or replace your order, no questions asked!</span>
                                        </span>
                                    </div>
                                    <div class="pr-benefit ttip">
                                        <span class="benefit-icon">
                                            <i class="icon-back"></i>
                                        </span>
                                        <span class="benefit-title">
                                            Easy Returns
            <span class="ttip-info" style="">If you are unhappy with your purchase for any reason you can return the items to us for an exchange or refund. Simply contact us within 30 days of receipt.</span>
                                        </span>
                                    </div>
                                </div>

                                <div class="col-xs-12 benefit-half last">
                                    <div class="pr-benefit ttip">
                                        <span class="benefit-icon">
                                            <i class="icon-lock"></i>
                                        </span>
                                        <span class="benefit-title">
                                            100% Secure Ordering
                                                                <span class="ttip-info">We guarantee the security of your personal information whether you pay for your order by credit card, by Western Union, or any of our alternative payment methods.</span>
                                        </span>
                                    </div>
                                    <div class="pr-benefit ttip">
                                        <span class="benefit-icon">
                                            <i class="icon-eye"></i>
                                        </span>
                                        <span class="benefit-title">
                                            Your privacy Valued
                                                               <span class="ttip-info">We respect your privacy. We do not share our customers’ billing or contact information with any third parties. View our privacy policy for more details!</span>
                                        </span>
                                    </div>
                                </div>
                            </div>
                        </div>
                        <hr class="delimiter small">

                        <!-- AddThis Button BEGIN -->
                        <div class="addthis_toolbox addthis_default_style addthis_32x32_style">
                            <a class="addthis_button_facebook"></a>
                            <a class="addthis_button_twitter"></a>
                            <a class="addthis_button_pinterest_share"></a>
                            <a href="whatsapp://send" data-text="Take a look at this awesome product:" data-href="" class="wa_btn wa_btn_m" style="display:none">Share</a>
                        </div>
                        <script type="text/javascript" src="//s7.addthis.com/js/300/addthis_widget.js#pubid=xa-538336b10eef5415"></script>
                         <!-- AddThis Button END -->
                 </div>
                  </div>
                </div>
            </div>
            <a name="pr-reviews"></a>
         <script type="text/javascript" src="catalog/javascript/pic_tab.js"></script>
         <script type="text/javascript">
			$('#responsive-slider').banqh({
				box:"#responsive-slider",//总框架
				pic:"#slider_pic",//大图框架
				pnum:"#ban_num1",//小图框架
				prev_btn:"#prev_btn1",//小图左箭头
				next_btn:"#next_btn1",//小图右箭头
				pop_prev:"#prev2",//弹出框左箭头
				pop_next:"#next2",//弹出框右箭头
				prev:"#prev1",//大图左箭头
				next:"#next1",//大图右箭头
				pop_div:"#pm-block",//弹出框框架
				pop_pic:"#ban_pic2",//弹出框图片框架
				pop_xx:".pop_up_xx",//关闭弹出框按钮
				bg:".bg",//朦灰层
				autoplay:false,//是否自动播放
				interTime:5000,//图片自动切换间隔
				delayTime:400,//切换一张图片时间
				pop_delayTime:400,//弹出框切换一张图片时间
				order:0,//当前显示的图片（从0开始）
				picdire:true,//大图滚动方向（true为水平方向滚动）
				mindire:true,//小图滚动方向（true为水平方向滚动）
				min_picnum:3,//小图显示数量
				pop_up:false//大图是否有弹出框
			})
		</script>
	  <hr class="delimiter hidden-xs">
      <div class="product-colateral hidden-xs row">
      	<div class="col-sm-24 tabbox_a prodetailsinfo_b">
        	<ul class="tabbox_name tab-links">
                <li class="tabtitle tabtitle_1"><a>Product Details</a></li>
                <li class="tabtitle tabtitle_2"><a>Product Q&A <?php if($question_total>0){?><span class="review-nr">- <span class="product-powerreviews-count"><?php echo $question_total;?></span></span><?php }?></a></li>
                <li class="tabtitle tabtitle_3"><a>Product Reviews <?php if($review_total>0){?><span class="review-nr">- <span id="product-questions-count"><?php echo $review_total;?></span></span><?php }?></a></li>
                <li class="tabtitle tabtitle_4"><a>Payment & Shipping</a></li>
            </ul>

                <?php if(!isMobile()) : ?>
            <div class="tabcont tab-pane prodetailsdes">
                <div class="output">
                  <?php if ($vedio) {?>
                    <p class="video"><iframe width="640" height="360" src="<?php echo $vedio; ?>" frameborder="0" allowfullscreen></iframe></p>
                  <?php }?>
                    <?php echo $description; ?>
                     <?php  foreach ($desc_images as $f_image) { ?>
                      <p  align="center"><img src="<?php echo $f_image; ?>" /></p>
                    <?php } ?>
                </div>
             </div>
                <!--Q&A start-->
              	<div class="tabcont tab-pane proconsult">
                    <div class="output">
                        <?php echo $question; ?>
                    </div>
                </div>
                <!--Q&A end-->
                <!--Reviews start-->
                <div class="tabcont tab-pane prorecords">
                    <div class="output">
                        <?php echo $review; ?>
                    </div>
                </div></div>
                <!--Reviews end-->
                <?php endif; ?>
                <!--Payment start-->
                <div class="tabcont tab-pane proargument">
                   <div class="output">
                     <table  width="100%" border="0" class="form-horizontal table-proargument">
                        <tr class="form-group"><td colspan="2"><h3>How to Buy</h3></td></tr>

                              <tr class="form-group">
                               	<td  height="80" align="left" colspan="2"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/shoping.gif" class="proargument-img" /></td>
                              </tr>


                         <tr class="form-group">
                             <td colspan="2"><h3>Shipping Method</h3></td>
                         </tr>

                          <tr class="form-group">
                            <td align="left" height="120">
                                <div style="margin:10px 0 0; text-align:center;"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/express_dhl.png" /></div>
                                <div style="margin:10px 0; text-align:center;"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/ems.gif" /></div>
                                <div style="margin:10px 0; text-align:center;"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/ChinaPostSAL.gif" style="border:1px solid #ddd; margin-right:10px;"></div>
                                <div style="text-align:center;"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/HKPost.gif" style="border:1px solid #ddd;margin-right:10px;"/></div>
                            </td>
                            <td align="left" style="line-height:20px">
                              <meta name="description" content="I like this. Do you think I should buy it?" />
                              <p style=" line-height:150%; margin:8px 0;">All items have stock enough. Normally we provide 2 kinds shipping methods (standard and express) options in your shopping cart. Standard shipping is for free and often ship by China Post Air Parcel or Hong Kong Air Parcel, it take about up to 30 days to delivery. Express shipping need extra $50 USD, often ship by EMS, DHL, UPS, FEDEX and etc. The delivery speed is more fast, usually 5-10 days to delivery. Both of 2 kinds shipping methods, delivery to door are guaranteed. In addition, we are not responsible for buyers customs taxes or VAT. But we try our best to help buyer lower or avoid customs duties, usually write a value of USD $50-100 on package and describle item as "Family Gift". If you have any special requirement, please leave a order message to tell us when you place an order. </p>

                              <table cellspacing="0" cellpadding="0" style="margin-top:12px;" class="tablewarp" width="100%">
                                       <tbody>
                                           <tr>
                                               <td width="27%" style="font-size:14px; font-weight:600; text-indent:0; text-align:center" rowspan="8">Standard Shipping<br /><span style=" font-weight:normal;">(Hong Kong EMS)</span>
</td>
                                               <td width="43%"><b>Country</b></td>
                                               <td width="30%"><b>Delivery Time</b></td>
                                           </tr>
                                           <tr>
                                               <td>USA</td>
                                               <td>7-10 work days</td>
                                           </tr>
                                           <tr>
                                               <td>Australia</td>
                                               <td>5-7 work days</td>
                                           </tr>
                                           <tr>
                                               <td>Singapore</td>
                                               <td>3-5 work days</td>
                                           </tr>
                                           <tr>
                                               <td>Malaysia</td>
                                               <td>5-6 work days</td>
                                           </tr>
                                           <tr>
                                               <td>Canada</td>
                                               <td>6-8 work days</td>
                                           </tr>
                                           <tr>
                                               <td>England</td>
                                               <td>8-12 work days</td>
                                           </tr>
                                           <tr>
                                               <td>Other Countries</td>
                                               <td>7-15 work days</td>
                                           </tr>
                                           <tr>
                                               <td colspan="3">Standard shipping track link: &nbsp;&nbsp;<a target="_blank" href="http://www.17track.net/en">http://www.17track.net/en</a></td>
                                           </tr>
                                       </tbody>
                                </table>
                              <table cellspacing="0" cellpadding="0" class="tablewarp" style="margin-top:12px;">
                                    <tbody>
                                        <tr>
                                            <td width="27%" style="font-size:14px; font-weight:600; text-indent:0; text-align:center" rowspan="6">Express Shipping<br /><span style="line-height:150%; font-weight:normal; font-color:red"><p>(EMS, DHL, UPS, FEDEX, ARMEX, Russia Express)</p></span>
                                            <td width="43%"><b>Country</b></td>
                                            <td width="30%"><b>Delivery Time</b></td>
                                        </tr>
                                        <tr>
                                            <td>United States, Canada</td>
                                            <td>6-8 work days</td>
                                        </tr>
                                        <tr>
                                            <td>Australia, New Zealand, Singapore</td>
                                            <td>5-7 work days</td>
                                        </tr>
                                        <tr>

                                            <td>
                                                <div style="text-indent:0; padding:0 10px;">United Kingdom, France, Spain, Germany, Netherlands, Japan, Belgium, Denmark, Finland,Ireland, Norway, Portugal, Sweden, Switzerland</div></td>
                                            <td>6-9 work days</td>
                                        </tr>
                                        <tr>
                                            <td>Italy, Brazil, Russia</td>
                                            <td>7-14 work days</td>
                                        </tr>
                                        <tr>
                                            <td>Other countries</td>
                                            <td>8-12 work days</td>
                                        </tr>
                                        <tr>
                                            <td colspan="3">Express shipping track link: <a href="http://www.17track.net/en" target="_blank">http://www.17track.net/en</a></td>
                                        </tr>
                                    </tbody>
                                </table>

                            </td>
                          </tr>
                          <tr class="form-group"><td colspan="2"><h3>Return Policy</h3></td></tr>
                          <tr class="form-group">
                            <td align="center" height="100" rowspan="2"><img src="https://www.beststoreitems.com/catalog/template/beststoreitems/image/Recycle_Full.gif"  style="margin:10px 10px 0 0;"/></td>
                            <td align="left" style="line-height:150%;  vertical-align:middle;">If you are not satisfied with our products, please contact us within 7 days. We will give you a satisfied solution, Refund, exchange, resend and return are available. If you want to return your items, Products must be in the condition you received them and in the original box. For avoiding the dispute, Please feel free to contact us for any issus at first. Thanks for your understand!</td>
                          </tr>
                          </table>
                   </div>
                </div>
                <!--Payment end-->
                </div>
             </div>

             <!--product mobile-->
               	 	<div class="product-colateral mobile visible-xs row">
                        <div class="panel-group">
                        <?php if(isMobile()) : ?>
                          <!--mobile-1-->
                          <div class="panel panel-default">
                                <div class="panel-heading">
                                  <h4 class="panel-title">
                                    <a href="javascript:void(0);">Product Description</a>
                                  </h4>
                                </div>
                                <a name="pr_questions2"></a>
                                <div class="panel-collapse collapse" id="pr_description2" name="pr_description2">
                                  <div class="panel-body">
										<?php if ($vedio) {?>
                                          <p class="video"><iframe width="640" height="360" src="<?php echo $vedio; ?>" frameborder="0" allowfullscreen></iframe></p>
                                        <?php }?>
                                          <?php echo $description; ?>
                                          <?php foreach ($desc_images as $f_image) { ?>
                                          <p align="center"><img src="<?php $f_image; ?>" /></p>
                                          <?php }?>
                                  </div>
                                </div>
                          </div>
                          <!--mobile-1-end-->
                          <!--mobile-2-->
                          <div class="panel panel-default">
                            <div class="panel-heading">
                              <h4 id="pr_reviews2_title" class="panel-title"><a href="javascript:void(0);">Product Reviews</a></h4>
                            </div>
                            <div class="panel-collapse collapse">
                              <div class="panel-body">
                                <div id="customer-reviews-clone" class="box-reviews">
                                	<?php echo $review; ?>
                    			</div>

                              </div>
                            </div>
                          </div>
                          <!--mobile-2-end-->
                          <!--mobile-3-->
                          <div class="panel panel-default">
                            <div class="panel-heading">
                              <h4 class="panel-title">
                                <a href="javascript:void(0);">Product Q&A</a>
                              </h4>
                            </div>
                            <div class="panel-collapse collapse" id="pr_questions2">
                              <div class="panel-body">
                                <div id="customer-questions-mobile">
                                    <?php echo $question; ?>
                                </div>
                              </div>
                            </div>
                          </div>
                          <!--mobile-3-end-->
                      <?php endif; ?>
                        </div>
					</div>
             <!--product end-->

             <script type="text/javascript">
			 	$(document).ready(function(){
					  $('.panel-collapse').hide();
					  $('.panel-default:first').find('.panel-collapse').show();
					  $('.panel-heading h4').find('a').addClass("collapsed");
					  //$('.panel-default:first').find('.panel-heading a').removeClass("collapsed");
					  $(".panel-heading h4").click(function(){
					  	$(this).parent().siblings('.panel-collapse').slideToggle()
					});
				});
             </script>


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

    <input type="hidden" name="product_id" id="product_id" value="<?php echo $product_id; ?>" />

    <a id="cmt" rel="nofollow" href="#"></a>

    <script language="javascript" type="text/javascript">

	$(".benefit-half .ttip").hover(function(){
		$(this).addClass("hover")
		$(this).siblings(".ttip").removeClass("hover");
		},function(){
		$(this).removeClass("hover")
	});

    </script>
    </div>
</div>
</div>
<script type="text/javascript">
	// add to wishlist
	$('#wishlist-close-btn, #continue_shopping_btn_wish').click(function(){
        $('#wishlist').hide();
    })
	$("#link-wishlist").click(function(){
			var js_options="";
			<?php foreach ($options as $option) { ?>
			var op_vale=document.getElementsByName("option[<?php echo $option['option_id']; ?>]")[0].value;
				if (op_vale=='') {
					alert("Please select all product options!");
					document.getElementsByName("option[<?php echo $option['option_id']; ?>]")[0].focus();
					return false;
				}else{
					js_options=(js_options=='')?op_vale:(js_options+'.'+op_vale);
				}
			<?php } ?>

            <?php if(!$customer_logged){ ?>
				$('#wishlist').show();
				return false;
			<?php } ?>

			var product_id = $('#product_id').val();
			var quantity = $('#quantity').val();
			$.ajax({
					type:'GET',
					url: 'index.php?controller=product&action=ajax_addtowishlist&product_id='+product_id+'&quantity='+quantity+'&options='+js_options,
					dataType: 'json',
					success: function(json) {
						//alert(js_options);
						$('#wishlist').show();
						$('#wishlist_count').text(json['wishlist_count']);

					}
				});
			 return false;

		});


		// add to cart
		$('#atc-close-btn, #continue_shopping_btn').click(function(){
        	$('#atc-box').hide();
    //	window.location.reload();
    	})
    $("#addtocart").click(function(){
    	var js_options="";
        <?php foreach ($options as $option) { ?>
        var op_vale=document.getElementsByName("option[<?php echo $option['option_id']; ?>]")[0].value;
            if (op_vale=='') {
                alert("Please select all product options!");
                document.getElementsByName("option[<?php echo $option['option_id']; ?>]")[0].focus();
                return false;
            }else{
            	js_options=(js_options=='')?op_vale:(js_options+'.'+op_vale);
            }
        <?php } ?>
 //       alert(js_options);
        var product_id = $('#product_id').val();
        var quantity = $('#quantity').val();
        $.ajax({
                type:'GET',
                url: 'index.php?controller=product&action=ajax_addtocart&product_id='+product_id+'&quantity='+quantity+'&options='+js_options,
//              data: 'product_id=' + $('#product_id').val() + '&quantity=' + $('#quantity').val() + '&options=' + options,
                dataType: 'json',
                success: function(json) {
                    $('#shopping_cart_num').text(json['cart_count']);
                    $('#shopping_cart_total').text(json['cart_total']);
                    reloadCartHeader();
                    $('#atc-box').show();
                }
            });
         return false;
    });
    function showReviews() {
      $('.tabtitle').removeClass('active');
      $('.tabtitle_3').addClass('active');
      $('.tabcont').hide();
      $('.prorecords').show();
    }
</script>
