Rev 10863 | Rev 11169 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed
<!--offers--><?phpif(isset($home_featured_product) and !empty($home_featured_product) and count($home_featured_product)>0){?><div class="recommended-pd"><div class="head"><div>Featured products</div></div><div class="rec-hldr"><div class="rec-wrapper"><?php foreach ($home_featured_product as $product) {?><a class="rec-product" href="<?php echo $product['url']; ?>"><img src="<?php echo $product['image_url']; ?>" alt="recomended" onerror="imgDefault()"/><div class="pd-name"><?php echo $product['title']; ?></div><div class="pd-desc"><?php echo $product['description']; ?></div><div class="pd-price"><span>Rs</span><span><?php echo $product['mrp']; ?> </span><span><?php echo $product['price']; ?></span></div></a><!--rec-product--><?php } ?></div></div><!--rec-hldr--></div><!--recomended-pd--><?php}else{//echo 'API\'s not returning any value. Please Contact Super Administrator! - '.basename(__FILE__).'<br>';}?><script type="text/javascript">var isIE10 = false;/*@cc_onif (/^10/.test(@_jscript_version)) {isIE10 = true;}@*/var iOS = navigator.userAgent.match(/(iPad|iPhone|iPod)/g);var ua = navigator.userAgent;var userAgent = navigator.userAgent.toLowerCase();if (isIE10) {var a = document.getElementsByClassName('rec-hldr');for (var i = 0; i < a.length; i++) {a[i].style.overflowX = 'auto';}} else if (ua.indexOf("Android") >= 0) {var androidversion = parseFloat(ua.slice(ua.indexOf("Android") + 8));if (androidversion < 3.0) {var script = document.createElement("script");script.type = "text/javascript";script.src = base_url+'assets/js/iscroll-lite-min.m.js'document.body.appendChild(script);script.onload = function() {var point, pointStartX, pointStartY, deltaX, deltaY;var i, scroller = [], len = document.getElementsByClassName('rec-wrapper').length;var scrollerArray = document.getElementsByClassName('rec-wrapper');for ( i = 0; i < scrollerArray.length; i++) {var length = scrollerArray[i].children.length;scroller[i] = new iScroll("swipe_" + i, {bounce : true,momentum : true,//hScroll: true,vScroll : false,hScrollbar : false,vScrollbar : false,snap : true,onBeforeScrollStart : function(e) {console.log("onBeforeScrollStart");point = e.touches[0];pointStartX = point.pageX;pointStartY = point.pageY; null;},onBeforeScrollMove : function(e) {console.log(e);point = e.touches[0];//alert("onBeforeScrollMove");deltaX = Math.abs(point.pageX - pointStartX);deltaY = Math.abs(point.pageY - pointStartY);if (deltaX >= deltaY) {e.preventDefault();// alert("horizontal");} else {//alert("vertical");null;}}});}setTimeout(function() {for ( i = 0; i < len; i++) {scroller[i].refresh();}}, 100);}} else {var a = document.getElementsByClassName('rec-hldr');for (var i = 0; i < a.length; i++) {a[i].style.overflowX = 'auto';a[i].style.webkitOverflowScrolling = 'touch';}}} else if (iOS) {if (navigator.userAgent.match(/(iPad|iPhone|iPod|iPod touch);.*CPU.*OS (6|7)_\d/i) ? true : false) {var a = document.getElementsByClassName('rec-hldr');for (var i = 0; i < a.length; i++) {a[i].style.overflowX = 'auto';a[i].style.overflowY = 'hidden';a[i].style.webkitOverflowScrolling = 'touch';}} else {var script = document.createElement("script");script.type = "text/javascript";script.src = base_url+'assets/js/iscroll-lite-min.m.js';document.body.appendChild(script);script.onload = function() {var point, pointStartX, pointStartY, deltaX, deltaY;var i, scroller = [], len = document.getElementsByClassName('rec-wrapper').length;var scrollerArray = document.getElementsByClassName('rec-wrapper');for ( i = 0; i < scrollerArray.length; i++) {var length = scrollerArray[i].children.length;scroller[i] = new iScroll("swipe_" + i, {bounce : true,momentum : true,//hScroll: true,vScroll : false,hScrollbar : false,vScrollbar : false,snap : true,onBeforeScrollStart : function(e) {console.log("onBeforeScrollStart");point = e.touches[0];pointStartX = point.pageX;pointStartY = point.pageY; null;},onBeforeScrollMove : function(e) {console.log(e);point = e.touches[0];//alert("onBeforeScrollMove");deltaX = Math.abs(point.pageX - pointStartX);deltaY = Math.abs(point.pageY - pointStartY);if (deltaX >= deltaY) {e.preventDefault();// alert("horizontal");} else {//alert("vertical");null;}}});}setTimeout(function() {for ( i = 0; i < len; i++) {scroller[i].refresh();}}, 100);}}} else if (ua.indexOf("BlackBerry") >= 0 || ua.indexOf("BB10") >= 0) {var a = document.getElementsByClassName('rec-hldr');for (var i = 0; i < a.length; i++) {a[i].style.overflowX = 'auto';a[i].style.webkitOverflowScrolling = 'touch';}}function imgDefault(){this.event.srcElement.src = base_url+'/assets/images/default-img.jpg';}</script>