162. Araxis Merge File Comparison Report

Produced by Araxis Merge on 2024-03-04 14:38:52 +0000. See www.araxis.com for information about Merge. This report uses XHTML and CSS2, and is best viewed with a modern standards-compliant browser. For optimum results when printing this report, use landscape orientation and enable printing of background images and colours in your browser.

162.1 Files compared

#LocationFileLast Modified
1/Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.7/app/design/frontend/Smartwave/porto/Smartwave_Porto/templates/ajaxproductsajaxproducts.phtml2023-01-06 02:56:18 +0000
2/Users/coca/Documents/www/Porto v4.0.2/Theme Files/Magento 2.x/Porto Theme v4.0.8/app/design/frontend/Smartwave/porto/Smartwave_Porto/templates/ajaxproductsajaxproducts.phtml2024-03-02 11:16:33 +0000

162.2 Comparison summary

DescriptionBetween
Files 1 and 2
Text BlocksLines
Unchanged3228
Changed00
Inserted25
Removed00

162.3 Comparison options

WhitespaceConsecutive whitespace is treated as a single space
Character caseDifferences in character case are significant
Line endingsDifferences in line endings (CR and LF characters) are ignored
CR/LF charactersNot shown in the comparison detail
Active line-pairing rules

162.4 Active regular expressions

No regular expressions were active.

162.5 Comparison detail

1 <?php 1 <?php
2 /** 2 /**
3  * Copyright © 2018 Porto. All rights reserved. 3  * Copyright © 2018 Porto. All rights reserved.
4  */ 4  */
5  5 
6 ?> 6 ?>
7 <?php 7 <?php
8 /** 8 /**
9  * Top menu for store 9  * Top menu for store
10  * 10  *
11  * @see \Smartwave\Megamenu\Block\Topmenu 11  * @see \Smartwave\Megamenu\Block\Topmenu
12  */ 12  */
13 ?> 13 ?>
14 <?php 14 <?php
15     $_helper = $this->helper('Smartwave\Megamenu\Helper\Data'); 15     $_helper = $this->helper('Smartwave\Megamenu\Helper\Data');
16     $_portohelper = $this->helper('Smartwave\Porto\Helper\Data'); 16     $_portohelper = $this->helper('Smartwave\Porto\Helper\Data');
17  17 
18     $categories = $_helper->getFirstLevelCategories(); 18     $categories = $_helper->getFirstLevelCategories();
19     $_category_config = $_portohelper->getConfig('porto_settings/category'); 19     $_category_config = $_portohelper->getConfig('porto_settings/category');
20     $_category_grid_config = $_portohelper->getConfig('porto_settings/category_grid'); 20     $_category_grid_config = $_portohelper->getConfig('porto_settings/category_grid');
21  21 
22     $aspect_ratio = $this->getData("aspect_ratio"); 22     $aspect_ratio = $this->getData("aspect_ratio");
23     if($aspect_ratio == null) { 23     if($aspect_ratio == null) {
24         $aspect_ratio = $_category_config['aspect_ratio']; 24         $aspect_ratio = $_category_config['aspect_ratio'];
25     } 25     }
26     $ratio_width = $this->getData("image_width"); 26     $ratio_width = $this->getData("image_width");
27     if(!$ratio_width) { 27     if(!$ratio_width) {
28         $ratio_width = ($_category_config['ratio_width'])?$_category_config['ratio_width']:300; 28         $ratio_width = ($_category_config['ratio_width'])?$_category_config['ratio_width']:300;
29     } 29     }
30     $ratio_height = $this->getData("image_height"); 30     $ratio_height = $this->getData("image_height");
31     if(!$ratio_height) { 31     if(!$ratio_height) {
32         $ratio_height = ($_category_config['ratio_height'])?$_category_config['ratio_height']:300; 32         $ratio_height = ($_category_config['ratio_height'])?$_category_config['ratio_height']:300;
33     } 33     }
34     $lazy_owl = $this->getData("lazy_owl"); 34     $lazy_owl = $this->getData("lazy_owl");
35     if(!$lazy_owl) 35     if(!$lazy_owl)
36         $lazy_owl = 0; 36         $lazy_owl = 0;
37     $product_count = $this->getData("product_count"); 37     $product_count = $this->getData("product_count");
38     if(!$product_count) 38     if(!$product_count)
39         $product_count = 8; 39         $product_count = 8;
40     $columns = $this->getData("columns"); 40     $columns = $this->getData("columns");
41     if(!$columns) 41     if(!$columns)
42         $columns = 4; 42         $columns = 4;
43 ?> 43 ?>
44 <div class="ajax-products"> 44 <div class="ajax-products">
45     <div class="category-list col-md-2"> 45     <div class="category-list col-md-2">
46         <span><?php echo __('Shop by'); ?>:</span> 46         <span><?php echo __('Shop by'); ?>:</span>
47         <ul> 47         <ul>
48         <?php 48         <?php
49             foreach($categories as $category) { 49             foreach($categories as $category) {
50                 $cat_id = $category->getId(); 50                 $cat_id = $category->getId();
51                 if($category->getIsActive()) { 51                 if($category->getIsActive()) {
52                     echo '<li><a class="" cat_id="'.$cat_id.'" href="javascript:void(0)"><span>'.$category->getName().'</span></a></li>'; 52                     echo '<li><a class="" cat_id="'.$cat_id.'" href="javascript:void(0)"><span>'.$category->getName().'</span></a></li>';
53                 } 53                 }
54             } 54             }
55         ?> 55         ?>
56         </ul> 56         </ul>
57     </div> 57     </div>
58     <div class="category-detail col-md-10"> 58     <div class="category-detail col-md-10">
59         <div class="ajax_products_loader" style="text-align: center; display: none;"><i class="ajax-loader large animate-spin" style="position: absolute;top: 50%;top: 35vh;margin-top: -20px;left: 50%;margin-left: -18px;"></i></div> 59         <div class="ajax_products_loader" style="text-align: center; display: none;"><i class="ajax-loader large animate-spin" style="position: absolute;top: 50%;top: 35vh;margin-top: -20px;left: 50%;margin-left: -18px;"></i></div>
60         <div class="products-area"></div> 60         <div class="products-area"></div>
61     </div> 61     </div>
62 </div> 62 </div>
63 <div class="clearer"></div> 63 <div class="clearer"></div>
64 <script type="text/javascript"> 64 <script type="text/javascript">
65     require([ 65     require([
66         'jquery', 66         'jquery',
67         'catalogAddToCart' 67         'catalogAddToCart'
68     ], function ($) { 68     ], function ($) {
69         $(".ajax-products > .category-list > ul > li > a").off("click").on("click", function(){ 69         $(".ajax-products > .category-list > ul > li > a").off("click").on("click", function(){
70             url = "<?php echo $_portohelper->getBaseLinkUrl()."swporto/index/showcategoryproducts" ?>"; 70             url = "<?php echo $_portohelper->getBaseLinkUrl()."swporto/index/showcategoryproducts" ?>";
71             cat_id = $(this).attr("cat_id"); 71             cat_id = $(this).attr("cat_id");
72             $(this).parent().parent().children("li").children("a").removeClass("active"); 72             $(this).parent().parent().children("li").children("a").removeClass("active");
73             $(this).addClass("active"); 73             $(this).addClass("active");
74             $(".ajax-products > .category-detail > .ajax_products_loader").fadeIn(); 74             $(".ajax-products > .category-detail > .ajax_products_loader").fadeIn();
75  75 
76             $.ajax({ 76             $.ajax({
77                 method:"POST", 77                 method:"POST",
78                 url:url, 78                 url:url,
79                 data:{ 79                 data:{
80                     aspect_ratio:"<?php echo $aspect_ratio; ?>", 80                     aspect_ratio:"<?php echo $aspect_ratio; ?>",
81                     image_width:"<?php echo $ratio_width; ?>", 81                     image_width:"<?php echo $ratio_width; ?>",
82                     image_height:"<?php echo $ratio_height; ?>", 82                     image_height:"<?php echo $ratio_height; ?>",
83                     product_count:"<?php echo $product_count; ?>", 83                     product_count:"<?php echo $product_count; ?>",
84                     columns:"<?php echo $columns; ?>", 84                     columns:"<?php echo $columns; ?>",
85                     category_id:cat_id 85                     category_id:cat_id
86                 }, 86                 },
87                 dataType: 'json' 87                 dataType: 'json'
88             }).done(function(data){ 88             }).done(function(data){
89                 $(".ajax-products > .category-detail > .products-area").html(data.result); 89                 $(".ajax-products > .category-detail > .products-area").html(data.result);
90                 if($("form[data-role=tocart-form]").length > 0 && !redirect_cart) { 90                 if($("form[data-role=tocart-form]").length > 0 && !redirect_cart) {
91                     $("form[data-role=tocart-form]").catalogAddToCart(); 91                     $("form[data-role=tocart-form]").catalogAddToCart();
92                 } 92                 }
93                 if(typeof enable_quickview != 'undefined' && enable_quickview == true) { 93                 if(typeof enable_quickview != 'undefined' && enable_quickview == true) {
94                     requirejs(['jquery', 'weltpixel_quickview' ], function($, quickview) { 94                     requirejs(['jquery', 'weltpixel_quickview' ], function($, quickview) {
95                         $('.weltpixel-quickview').off('click').on('click', function() { 95                         $('.weltpixel-quickview').off('click').on('click', function() {
96                             var prodUrl = $(this).attr('data-quickview-url'); 96                             var prodUrl = $(this).attr('data-quickview-url');
97                             if (prodUrl.length) { 97                             if (prodUrl.length) {
98                                 quickview.displayContent(prodUrl); 98                                 quickview.displayContent(prodUrl);
99                             } 99                             }
100                         }); 100                         });
101                         $(".ajax-products .products-grid .weltpixel-quickview").each(function(){ 101                         $(".ajax-products .products-grid .weltpixel-quickview").each(function(){
    102                             $(this).parent().parent().addClass('has-quickview');
    103                             if($(this).parents('.product-type-advanced').find(".product-item-photo.porto-tb-featured-image .icon-absolute").length > 0){
    104                               $(this).appendTo($(this).parents('.product-type-advanced').find(".product-item-photo .porto-tb-featured-image .product-item-inner .product-item-actions"));
    105                             }else{
102                             $(this).appendTo($(this).parent().parent().children(".product-item-photo")); 106                               $(this).appendTo($(this).parent().parent().children(".product-item-photo"));
    107                             }
103                         }); 108                         });
104                     }); 109                     });
105                 } 110                 }
106             }).fail(function(){ 111             }).fail(function(){
107  112 
108             }).always(function(){ 113             }).always(function(){
109                 $(".ajax-products > .category-detail > .ajax_products_loader").fadeOut(); 114                 $(".ajax-products > .category-detail > .ajax_products_loader").fadeOut();
110             }); 115             });
111         }); 116         });
112         $(".ajax-products > .category-list > ul > li:first-child > a").click(); 117         $(".ajax-products > .category-list > ul > li:first-child > a").click();
113     }); 118     });
114 </script> 119 </script>