Questions tagged [page-layouts]

In Magento many different Page layouts are available. The layout of each page in your store consists of distinct sections, or containers, that define the header, footer, and content areas of the page. Depending on the layout, each page might have one, two, three columns, or more. You can think of the layout as the floor plan of the page, and assign a specific layout to be used as the default for CMS, product, and category pages. It's Simply XML files.

Filter by
Sorted by
Tagged with
0 votes
1 answer
11 views

Page configuraion is not in its right place (page_layout/catalog_category_view.xml)?

This file (vendor/magento/module-page-builder/view/frontend/page_layout/catalog_category_view.xml) belongs to namespace xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/...
0 votes
1 answer
110 views

Full width product gallery

I am using a custom theme built off of Amasty's Jet Theme. I am trying to use the grouped product type to sell parts from a schematics image. The idea is to have the schematic full width across the ...
  • 33
0 votes
1 answer
341 views

how to override module-page-builder/view/frontend/layouts.xml

i want to override module-page-builder/view/frontend/layouts.xml. please help me. i am not able to override. Thanks
0 votes
1 answer
105 views

Change price template only for product on product page and not for other sections like related products sections

I was able to change the price design for only product page using the solution in this link Change price template only for product view page? My code: In catalog_product_view.xml file I have added ...
0 votes
1 answer
248 views

Magento 2.4: How to fix admin page layout broken?

I have an issue that after i try to change admin page content this issue happenend. Can anybody show me how to fix this error and how to improve it.
0 votes
1 answer
244 views

Duplicate breadcrumbs in catalog_product_view.xml

I am trying to duplicate breadcrumbs in product page, as so to be able to hide and show it in different positions for mobile and desktop devices. I have tried the following but breadcrumb shows only ...
0 votes
2 answers
654 views

Magento 2 - Custom page layout not working properly

I have some big grouped products (with sku: montagekonsole and montageschiene). I need to change the layout for both. First I just created custom sku handles for each product like this: THEME/...
  • 2,903
0 votes
1 answer
52 views

Magento 2 - Custom page layout destroys view

I added a new page layout which inherits from the page layout 1column: THEME\Magento_Theme\layouts.xml <?xml version="1.0"?> <layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
  • 2,903
0 votes
2 answers
494 views

Magento 2 - remove block if page layout is XY

I need to remove a block named "header_top_content" by using a layout xml file, but only on CMS sites with page layout set to "empty". Is this possible via layout or not? I tried ...
  • 2,903
0 votes
1 answer
210 views

Anybody know the Reference block name for the Footer->Miscellaneous HTML

Within Content->Design->Configuration->Theme->Footer->Miscellaneous HTML I have added some HTML and it works correctly However, I use a popup and it also displays at the bottom of the ...
  • 431
0 votes
1 answer
21 views

How to replace a .phml file without rewrite the entire block

I have a custom extension working fine. It has some features that only usable when this extension is installed and enabled so I decided to create a custom footer.phtml and put it under my extension ...
  • 3
0 votes
1 answer
209 views

How to remove specific JS and CSS in Magento2 using page_layout/empty.xml

I have created New page_layout empty.xml. I need to remove some JS and CSS from this layout. I already try <remove src="print.css"/> But it gives an error Exception #0 (Magento\...
1 vote
0 answers
226 views

Add custom to field to CMS page based on template in Magento 2

I have several custom fields I added to my CMS pages but I only want them to show up on the backend if the admin user selects a specific template. For example, the text field "doctor name" ...
  • 163
0 votes
2 answers
87 views

how to add a line in between 2 block

HI I am trying to change the look of the customer login page. How do add a line or separator in between this 2 blocks? like the image I found on net. When in mobile view the line will gone.
  • 602
0 votes
1 answer
189 views

Layout switcher for product view magento 2.3.5 (Custom layout update)

Since the update to Magento 2.3.x it is possible to change the layout of the product output using a product id or sku: https://devdocs.magento.com/guides/v2.3/frontend-dev-guide/layouts/product-...
  • 458
0 votes
1 answer
90 views

Magento 2.3: Checkout page displays only `loading image` after checkout_index_index.xml was overridden in the custom theme

The checkout page now display loading image forever after I have overridden the checkout_index_index.xml in the custom theme to remove faxfield from the checkout page. Below is the screenshot showing ...
1 vote
0 answers
116 views

Error add new block into block Magento 2

I'm using Magento 2.3.4 and t tried to append a block to another block like this in my controller: $category_list_subcategories = $resultPage->getLayout()->getBlock('promotion.view....
  • 109
-1 votes
1 answer
144 views

Magento2 static block now being moved via xml

I have a Magento2.4 based site and I edited the default.xml to load static cms block in the footer div and align them next to each other. My issue is one of the static blocks keeps appear outside the ...
  • 705
1 vote
1 answer
473 views

Magento2 - How to remove the side navigation bar only in my account page?

I need to remove the side bar only in My Account page. I had removed the side bar in Magento_Customer > Layout > customer_account.xml but it removes from all the pages like (my address page,...
  • 318
1 vote
1 answer
211 views

Remove the image slider in product detail page

I want to to remove the slider in images What I want it to be like :
1 vote
2 answers
193 views

Magento 2: Product Detail Layout change

I want to make the product detail into 2 Columns with images at the side and description on the other side... I want the right side containing the detail to be sticky while scrolling and left side ...
1 vote
1 answer
70 views

Magento2 - Adobe XD to Magento2 font size

On the xd design the font-size is 55 and when I apply this font-size in my Magento layout It is bigger ? Why is it so?
1 vote
0 answers
65 views

Magento 2 How can I add 2columns-left in container area like the one I have shared

I want to add 2 columns one for the menu and other for the text in container Page.top is the menu container which I have move into a new container Now In that new container page top after banner I ...
0 votes
4 answers
2k views

Magento 2 Move Short Description below product image

I am new to magento2 and I have very few knowledge about it, I am using Porto theme on magento 2.3.0 CE. I am trying to move the short description under the product image. Here is what I have : Here ...
  • 1
0 votes
1 answer
28 views

Important div tag commented out when on production mode

We noticed that some of our page layout has been broken. Did some debugging and found out that when in production mode there are some errors with the tags. Specifically: <!--?php <?php <?...
0 votes
1 answer
163 views

Magento 2.3.3: Does catalog_product_view.xml not pass down containers to specific product types?

I have created a catalog_product_view.xml in my theme and when I go to create a widget and select all product types in the layout updates section I can see my custom container I created. If I then ...
  • 98
0 votes
0 answers
89 views

How do I refresh data when I hit Tab on the left in magento2

When developing editing pages of background management pages, currently magento2 does not refresh the data when switching different Tab pages. I want to refresh the page data when switching tabs. What ...
3 votes
1 answer
2k views

Page Title Move for All Pages - Magento2

<div class="columns"> <div class="column main"> <div class="page-title-wrapper"> <h1 class="page-title"> <span class="base" data-ui-id="page-title-...
0 votes
1 answer
154 views

Magento 2 - what is the difference between layout and page_layout?

I want to override page_layout file product-full-width.xml I was trying to override this in app/design/frontend/Company_Name/Theme_Name/app/design/frontend/Company_Name/Theme_Name/Magento_Theme/...
  • 7
0 votes
2 answers
152 views

product detail page - move block to primary product container

I would like to move the static block (a custom block from infortis ultimo theme) block_product_secondary_bottom to the container_product_primary_1 container after product.info.price. How do I do that?...
0 votes
2 answers
2k views

Magento2 Move static block to above footer and below main content

In my magento2 based website I have a static block that i want to load right before the footer block but below the main content of the page. I have tried the below but that did not seem to make it ...
  • 705
0 votes
1 answer
50 views

Magento2 - Modify surrounding divs of layouts

I'm using the 2columns-left as a layout for my category pages and I want to modify these divs, change their classes, without having to add javascript afterwards. I can already modify the templates ...
  • 81
0 votes
2 answers
299 views

How i Can Move Side Bar to Right on My Account Page

I want to Move Side-bar on My Account Page to Right On The Basis Of Admin Configuration Value After Some Research i found that it can be done by setting Page layout="2coloums-right" i saw Lots of ...
  • 2,189
0 votes
2 answers
201 views

Magento 2 - Site not loading properly in Developer mode

I am working on M2 and I've set M2 developer mode. My site home page works fine but the other pages are not loading. They just show errors and warnings on inner pages. Screenshot:
0 votes
1 answer
98 views

Magento 2 - Admin product page layout issue

I am facing an issue while trying to go on the product page from a catalog in the admin. The product page grid layout not loading properly. Every time when I clear cache, page load correctly. What is ...
1 vote
1 answer
61 views

Failing to remove page title

I'm trying to remove page title added from Magento\Downloadable\Controller\Customer\Products::Execute public function execute() { $this->_view->loadLayout(); if ($block = $...
  • 3,714
0 votes
1 answer
544 views

Change page layout dynamically depending on url parameter

The standard layout of my categories is 2-columns-left so that the layered navigation is visible in my shop. What I want is, to use the same categories to display content. This is an example for my ...
0 votes
1 answer
117 views

Wrong Layouts in Magento2 Adminhtml

I noticed a strange behavior in a M2 System, I think this is related to a 3rd party module. All layouts which should be 1column layouts are 2 column layouts actually so something overwrites the ...
0 votes
1 answer
507 views

How to center a block on a page?

I have a block with a visual menu in it and I want to show up centered on the page. This is my css within the block: .container{ margin: 0 auto; text-align:center; } I've also tried to put the ...
2 votes
3 answers
292 views

Move block and set template

I succesfully moved the product related block in my page layout with <move element="catalog.product.related" destination="product.info.right" after='-'/> I want now to apply a custom template ...
  • 389
1 vote
1 answer
230 views

Move theme layout elements on a product view from within a Module Magento 2

I am having trouble moving the short description on the product page. I tried with the move command within the layout file without any luck. I can move any new created block where I want but I can't ...
  • 189
1 vote
1 answer
24 views

Magento : Is the layout reference scoped for an specific handle?

When I put the following block inside catalog_category_layered handle, it works and I can call it by getChildHtml(). But when I insert it in default handle it doesn't work at all. Is the catalog.layer....
2 votes
1 answer
1k views

Magento 2 Add css class to <a> tag in customer account navigation

I try to assign a CSS class to navigation ( tag) under customer account page. I found this file customer_account.xml, and I added <argument name="css_class" xsi:...
1 vote
1 answer
743 views

How to create custom 403 error page in magento2

How can I create a custom error pages in my Magento 2 site. For example this pages: 500, 401, 403, and 404. I tried for create block: $layout = $this->_view->getLayout(); $block = $layout-&...
  • 561
2 votes
1 answer
829 views

Magento 2 product page include custom phtml file before reviews section

Can anyone help me how to include custom phtml file before reviews section in magento2 please find the screenshot below: When i click on the button it is going to add to cart. Thanks
0 votes
1 answer
674 views

Magento 2: How to add block inside block html content through XML file

I have created my custom arithmetic captcha. I want add that captcha to my custom form through xml file without defining in phtml file on custom layout. For example: Testimonail submit form: ...
0 votes
1 answer
267 views

Magento 2 Block class instantiate issue

I am using Magento 2.2.6. In my custom module I add catalog_category_view.xml add a block <?xml version="1.0" ?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
1 vote
1 answer
5k views

Magento 2 custom layout full width

I created a new custom page_layout that I want to make full width. My fullwidth-layout.xml file looks currently like this. But I want to make the main content full width. So that I can set this ...
  • 1,436
0 votes
2 answers
3k views

Magento 2 add new argument in the reference block and get into the phtml

I am working on reference block concept, in that I need to add new arguments and get the argument value on the .phmlt file. in catalog_product_view.xml I've added the below line of code. <...
  • 1,647
1 vote
0 answers
89 views

Magento 2 - CMS Specific page_layout XML and Dedicated page_layouts in general?

I'm looking for some BEST PRACTICES insight into using page_layout.xml. Is it a good idea to try and decouple the non-shared resources on Product Pages, Category Pages and CMS Pages? If so, what's the ...
  • 579