Questions tagged [router]
The router tag has no summary.
114 questions
0 votes
1 answer
42 views
Create cutom router for redirecting to homepage || Magento 2
In Magento 2, I want to set custom route, like after baseurl/custom-route/any url it should be redirected to homepage or base url. Here, I had tried to create type of RouterList and extend ...
0 votes
1 answer
332 views
Magento 2 different routes per store view
I have one online store with two store views, English and French. How can I add different routes per store view in a custom module on a Magento 2.4 store, following the attached example? EN: www....
0 votes
2 answers
726 views
Magento 2 How create front controller with a specific path?
I want create controller for specific path, but i can't know how i can do this. My controller must work with path like: site.com/usa/some-review/dynamicParam My path for controller: site.com/some-...
0 votes
1 answer
1k views
Magento 2 Add Button in Edit Product page and land back there after POST request
So, as the title says, I want to add an Admin button in the Edit Product Admin page. That button, when pressed, will call the respective controller of a URL, sending along the product id, the ...
0 votes
0 answers
122 views
How to log route for every url?
I am trying to get the list of routers and followed this available module, but I am trying to get the router for every url that executed on the browser. In the code as shown below. foreach ($this->...
0 votes
1 answer
288 views
Route blog URL to custom route
I am using Magento 2 Magefan blog extension. The blog post URL is generated as below. http://store-url/blog/post/hurry-xmas-with-family But I want URL as below and it show the content of the above URL ...
0 votes
3 answers
2k views
Magento 2 Create Controller rendering Blank Page
I am new to Magento and I tried this tutorial where I will create a controller for Magento 2. https://www.mageplaza.com/magento-2-module-development/how-to-create-controllers-magento-2.html My problem ...
2 votes
1 answer
180 views
Add a custom/programmed block to a CMS page
I have created a page using the CMS (via Admin Portal) and now I want to add a custom block (programmed) to the page. You can see the created page here: My structure is the following: but ...