Produced by Araxis Merge on 2021-05-13 09:08:59 +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.
| # | Location | File | Last Modified |
|---|---|---|---|
| 1 | /Applications/Ampps/www/Porto 3.2.2/Theme Files/Magento 2.x/Porto Theme/app/code/Smartwave/Porto/Plugin | UpdateBodyClass.php | 2019-10-24 09:09:56 +0000 |
| 2 | /Applications/Ampps/www/Porto v4.0.0/Theme Files/Magento 2.x/Porto Theme/app/code/Smartwave/Porto/Plugin | UpdateBodyClass.php | 2021-03-15 02:47:54 +0000 |
| Description | Between Files 1 and 2 | |
|---|---|---|
| Text Blocks | Lines | |
| Unchanged | 4 | 80 |
| Changed | 3 | 10 |
| Inserted | 0 | 0 |
| Removed | 0 | 0 |
| Whitespace | Consecutive whitespace is treated as a single space |
|---|---|
| Character case | Differences in character case are significant |
| Line endings | Differences in line endings (CR and LF characters) are ignored |
| CR/LF characters | Not shown in the comparison detail |
| Active line-pairing rules |
No regular expressions were active.
| 1 | <?php | 1 | <?php | |||
| 2 | namespace Smartwave\Porto\Plugin; | 2 | namespace Smartwave\Porto\Plugin; | |||
| 3 | 3 | |||||
| 4 | use Magento\Framework\App\ResponseInterface; | 4 | use Magento\Framework\App\ResponseInterface; | |||
| 5 | 5 | |||||
| 6 | class UpdateBodyClass | 6 | class UpdateBodyClass | |||
| 7 | { | 7 | { | |||
| 8 | » private $context; | 8 | » private $context; | |||
| 9 | » protected $helper; | 9 | » protected $helper; | |||
| 10 | 10 | |||||
| 11 | » public function __construct( | 11 | » public function __construct( | |||
| 12 | » » \Magento\Framework\View\Element\Context $context, | 12 | » » \Magento\Framework\View\Element\Context $context, | |||
| 13 | » » \Smartwave\Porto\Helper\Data $helper | 13 | » » \Smartwave\Porto\Helper\Data $helper | |||
| 14 | » ) { | 14 | » ) { | |||
| 15 | » » $this->context = $context; | 15 | » » $this->context = $context; | |||
| 16 | » » $this->helper = $helper; | 16 | » » $this->helper = $helper; | |||
| 17 | » } | 17 | » } | |||
| 18 | 18 | |||||
| 19 | » public function beforeRenderResult(\Magento\Framework\View\Result\Page $subject, ResponseInterface $response) { | 19 | » public function beforeRenderResult(\Magento\Framework\View\Result\Page $subject, ResponseInterface $response) { | |||
| 20 | » » | 20 | ||||
| 21 | » » $page_layout = $this->helper->getConfig('porto_settings/general/layout'); | 21 | » » $page_layout = $this->helper->getConfig('porto_settings/general/layout'); | |||
| 22 | » » if($page_layout == "full_width") { | 22 | » » if($page_layout == "full_width") { | |||
| 23 | » $page_layout = "layout-fullwidth"; | 23 | » $page_layout = "layout-fullwidth"; | |||
| 24 | » } else if($page_layout == "1140") { | 24 | » } else if($page_layout == "1140") { | |||
| 25 | » $page_layout = "layout-1140"; | 25 | » $page_layout = "layout-1140"; | |||
| 26 | » } else if($page_layout == "1280") { | 26 | » } else if($page_layout == "1220") { | |||
| 27 | » $page_layout = "layout-1280"; | 27 | » $page_layout = "layout-1220"; | |||
| 28 | » } | 28 | » } | |||
| 29 | » » if($page_layout){ | 29 | » » if($page_layout){ | |||
| 30 | » » » $subject->getConfig()->addBodyClass($page_layout); | 30 | » » » $subject->getConfig()->addBodyClass($page_layout); | |||
| 31 | » » } | 31 | » » } | |||
| 32 | 32 | |||||
| 33 | » $boxed = $this->helper->getConfig('porto_settings/general/boxed'); | 33 | » $boxed = $this->helper->getConfig('porto_settings/general/boxed'); | |||
| 34 | » » if($boxed){ | 34 | » » if($boxed){ | |||
| 35 | » » » $subject->getConfig()->addBodyClass($boxed); | 35 | » » » $subject->getConfig()->addBodyClass($boxed); | |||
| 36 | » » } | 36 | » » } | |||
| 37 | 37 | |||||
| 38 | » » if ($this->helper->getConfig('porto_settings/header/mobile_sticky_header')) | 38 | » » if ($this->helper->getConfig('porto_settings/header/mobile_sticky_header')) | |||
| 39 | » $subject->getConfig()->addBodyClass("mobile-sticky"); | 39 | » $subject->getConfig()->addBodyClass("mobile-sticky"); | |||
| 40 | | 40 | //if ($this->helper->getConfig('porto_settings/header/header_type') == "10") | |||
| 41 | » | 41 | » //$subject->getConfig()->addBodyClass("side-header"); | |||
| 42 | 42 | |||||
| 43 | » » return [$response]; | 43 | » » return [$response]; | |||
| 44 | » } | 44 | » } | |||
| 45 | } | 45 | } |
Araxis Merge (but not the data content of this report) is Copyright © 1993–2019 Araxis Ltd (www.araxis.com). All rights reserved.