Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
module-cms
Controller
Page
View.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\Cms\Controller\Page
;
8
9
use
Magento\Framework\App\Action\HttpPostActionInterface
;
10
use
Magento\Framework\App\Action\HttpGetActionInterface
;
11
use
Magento\Framework\App\Action\Action
;
12
16
class
View
extends
Action
implements
HttpGetActionInterface
,
HttpPostActionInterface
17
{
21
protected
$resultForwardFactory
;
22
27
public
function
__construct
(
28
\
Magento
\Framework\
App
\
Action
\
Context
$context,
29
\
Magento
\Framework\Controller\Result\ForwardFactory
$resultForwardFactory
30
) {
31
$this->resultForwardFactory =
$resultForwardFactory
;
32
parent::__construct($context);
33
}
34
40
public
function
execute
()
41
{
42
$pageId = $this->
getRequest
()->getParam(
'page_id'
, $this->
getRequest
()->getParam(
'id'
,
false
));
43
$resultPage = $this->_objectManager->get(\
Magento
\Cms\Helper\Page::class)->prepareResultPage($this, $pageId);
44
if
(!$resultPage) {
45
$resultForward = $this->resultForwardFactory->create();
46
return
$resultForward->forward(
'noroute'
);
47
}
48
return
$resultPage;
49
}
50
}
Magento\Framework\App
Magento\Framework\App\Action\HttpGetActionInterface
Definition:
HttpGetActionInterface.php:16
Magento\Cms\Controller\Page\View\__construct
__construct(\Magento\Framework\App\Action\Context $context, \Magento\Framework\Controller\Result\ForwardFactory $resultForwardFactory)
Definition:
View.php:27
Magento\Cms\Controller\Page\View
Definition:
View.php:16
Magento\Framework\App\Action\AbstractAction\getRequest
getRequest()
Definition:
AbstractAction.php:60
Magento\Cms\Controller\Page\View\execute
execute()
Definition:
View.php:40
Magento\Cms\Controller\Page
Definition:
View.php:7
Magento
Magento\Framework\App\Action\HttpPostActionInterface
Definition:
HttpPostActionInterface.php:16
Context
Definition:
ClassesForConstructorIntegrity.php:33
Magento\Framework\App\Action\Action
Definition:
Action.php:25
Magento\Cms\Controller\Page\View\$resultForwardFactory
$resultForwardFactory
Definition:
View.php:21