Exam4Training

How do you name the file containing the action controller class so the admin router matches the path to the class?

The module MyCompany_MyModule will add a new page to the admin interface at the URL path admin/ mycompany/entity_grid.

How do you name the file containing the action controller class so the admin router matches the path to the class?
A . Controller/Adminhtml/Entity/Grid/Index.php
B . Controller/Adminhtml/Mycompany/Entity/Grid.php
C . Controller/Adminhtml/Entity/Grid.php
D . Controller/Adminhtml/Mycompany/Entity_Grid.php

Answer: D

Explanation:

Reference: https://www.mageplaza.com/magento-2-module-development/magento-2-routing.html

Exit mobile version