Questions tagged [xml]

Denotes questions about XML files and XML processing.

Filter by
Sorted by
Tagged with
2
votes
1answer
154 views

Module custom page 404 error

An extension I'm using creates two custom pages in website: app/design/frontend/mytheme/default/layout/scommerce_competition.xml <?xml version="1.0"?> <layout version="0.1.0"> <...
1
vote
0answers
108 views

Magento 2: understand processing order of layout handles and other directives?

I am preparing for certification on Magento 2 and I am having difficulty understanding this questions. Can anyone help me with these questions? Understand processing order of layout handles and other ...
0
votes
1answer
337 views

How add text in custom theme header magento 2

<referenceContainer name="header.wrapper"> <block class="Magento\Theme\Block\Html\Header" name="header.links" after="logo"> <arguments> <...
0
votes
2answers
157 views

Magento 2: Calling a cms block in default xml

I am trying to call a static block in the footer block but it does not work. I created a theme and then created a default xml: \app\design\frontend\MyTheme\Theme-frontend-default\Magento_Theme\...
2
votes
1answer
122 views

Overwrite Category Display Mode from “Static Content Only” to “Products Only” via Layout XML

I want to overwrite the "Display Mode" backend setting of a certain category via layout xml file (e.g. catalog_category_view_id_XYZ.xml). Any idea how to update the layout handle? I want to do this ...
0
votes
1answer
225 views

Magento 2 Add CMS/phtml block bottom before product_list_toolbar and after product_list (Between)

I am not able to add a cms block in category page. XML: <block class="Magento\Framework\View\Element\Template" name="catalog.filter.content.bottom" template="my_module::test.phtml"/> what I ...
1
vote
1answer
294 views

How to hide Vat number?

I want the VAT number filed on to present when i click the user to zero vat customer group.If click any other group i dont want to show the vat field. Anyone has any idea how to fix this. /private/...
2
votes
1answer
168 views

How to get to know the XML file and its path for that template Path Hint in Magento 2

As we can enable template path hints in settings along with blocks but there is no option to show from which xml file it is coming in the frontend. How should I know which xml file to write to move, ...
0
votes
1answer
141 views

Magento 2 overwrite checkout.cart.item.renderers block

I tried to set a new template for checkout.cart.item.renderers block and i found some issue, beucause I didn't know that i have to overwrite separately each type of product. I will post my solution, ...
0
votes
1answer
442 views

sitemap.xml shows different base path when generate

I have generated the sitemap for my live instance. But after generating it it is showing staging url in xml sitemap. When I see my xml sitemap in the browser for live site, it shows the links with ...
0
votes
2answers
959 views

Move related products to “Details” tab on product page

I would like to move related products to "Details" tab below description on product page.
1
vote
2answers
2k views

How to create custom cms page layout file?

In Magento 2, is there any solution to creating a custom layout XML file for custom cms page? I want to add XML code and CSS and Js only for my custom cms page. I know about there is one field ...
1
vote
2answers
204 views

Adding a Block between Menu and Breadcrumbs

Going a bit nuts trying to get my head around this. Debug mode doesn't help me. I'm trying to add a block just before the </header> on only Product Pages. I've created a phtml file with my ...
0
votes
1answer
21 views

I have an error pointing to this block class but i'm not sure what's wrong with it.. (magento 2.2.5)

A validation error occured in an XML layout file <block class="Magento\Cms\Block\Block" name="gbp_success_page-block"> <container name="gbp-fullwidth-hero-wrapper" as="heroWrapper" ...
2
votes
0answers
111 views

Element 'argument': The type definition is abstract and The state object to be removed is not the first in the list

I'm throwing this error on my /success/ page and it seems like such a generic error. It looks like further down the trace it's pointing to stuff like GoogleTagManager and other third-party modules ...
2
votes
1answer
205 views

Disable default magento free shipping method at frontend ONLY

Store -> Settings -> Configuration -> Sales -> Shipping Methods -> Free Shipping How can I disable this default feature of Magento in frontend only?
0
votes
1answer
685 views

Magento\Framework\Exception\LocalizedException: Invalid XML file 0.1.0 Payeezy Magento 2

Facing below error: >Magento\Framework\Exception\LocalizedException: Invalid XML in file 0.1.0 Payeezy_PayeezyCheckout_Model payeezycheckout_mysql4 Payeezy_PayeezyCheckout_Model_Mysql4 ...
5
votes
1answer
390 views

Magento2 : Use of echo language construct is discouraged

I have my RSS feed from controller returned /displayed on frontend using echo , how do I replace echo any alternate method availabale? MEQP1.Security.LanguageConstruct.DirectOutput public ...
1
vote
1answer
192 views

Remove order in customer dashboard

How to remove "recently order" in customer dashboard ? I tried this : <referenceBlock name="sale.reorder.sidebar" remove="true"/> but nothing happened
0
votes
2answers
602 views

Remove My Account top bar when user is not logged in

i want to remove magento top link My Account if user is not logged in ,i do not want to modify core files, i tried to get solution but could not find any working one . i tried below method in : "...
0
votes
0answers
228 views

Magento 2: Warning: simplexml_load_string(): Entity: line 1: parser error : XML declaration allowed only at the start of the document

I am using magento 2.0 I have learn magento2 tutorials(No frills magento2 layout) of alan storm. I have create two xml files. when i run controller file then give Following error Warning: ...
2
votes
1answer
27 views

How to apply “if” condition to XML generation file

I have a Magento 1.7 Community plataform, connected to an ERP (Bling). We have a file that take all those php information and send as an invoice to Bling. In our products, we have a field named "...
1
vote
1answer
36 views

Magento 2 | Blocks don't appear

I created a new page layout for my home page. I want it to display 3 blocks next to each other. It should look like this: I created the blocks in backend but with the below code they don't show up. ...
3
votes
1answer
36 views

magento 1.9 custom module fronted error 404

I have problem to acces the custom module frontend controller. I am following a basic tutorial to build a custom module. These are the files I've edited: /var/www/html/magento/app/etc/modules/...
1
vote
1answer
148 views

Magento Dataflow Advance Profile To Export Customer in Google Contact Format

I have difficulty to find any guide relating to this subject. Basically, I want to export all customer using magento dataflow profile export to csv, in a way so I can just import the csv to the google ...
2
votes
0answers
175 views

Syntax for overriding config.xml module configuration with config.php in magento2?

I have a module MyCompany_ExampleModule. Its etc/config.xml file: <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Store:etc/...
2
votes
1answer
258 views

Move breadcrumb before sort by feature of toolbar section in Magento2

How to move breadcrumb of category list page into toolbar section of category list page. I need to move the breadcrumb to toolbar or either left sidebar before the filters. Is it possible to do like ...
1
vote
1answer
750 views

Magento 2 Knockout XML->PHTML->JS->HTML

I want to display static block in html login popup during checkout, but there is a problem. This is the html template which is called from js, this js is called from phtml, and this phtml template ...
2
votes
0answers
63 views

How to trim text before saving in system.xml

In my custom module in system.xml in Admin I have field: <field id="user_key" translate="label" type="text" sortOrder="30" showInDefault="1" showInWebsite="1" showInStore="1"> <label&...
2
votes
1answer
25 views

Is it possible to display an XML Block based on an IF?

I use the below code in a module within catalog_product_view.xml to display a new Tab on the Product Page. <body> <referenceBlock name="product.info.details"> <block class="...
3
votes
3answers
141 views

What is “product wrapper” XML name?

I'm trying to move products element and can't find it's name to reference via XML. The element has class "products wrapper grid products-grid" in rendered HTML. Using Magento 2.
3
votes
2answers
139 views

Extending the `events.xml` file

I'm trying to disable the default UrlRewrite event observers in the magento-catalog-url-rewrite Module. I have extended the file under app/code/xyz/MagentoCatalogUrlRewrite/etc/events.xml, set the ...
0
votes
3answers
34 views

Magento 2 accidental theme move

I FTP'd into my server with filezilla. I accidentally moved one theme into another. I have since moved it back but now its pulling in the footer from its parent theme, luma. Default.xml and Default ...
0
votes
2answers
518 views

How to give condition in xml file for showing different block in different pages

How to give condition in xml file for showing different block in different pages. Like I place a block name "Footer Block" in default xml file, and I want different footer for different pages. &...
0
votes
1answer
88 views

Magento 2 - How to create a calculator

I've created a new module in magento 2 and I want to add some additional files so that I can create a calculator. I'm unsure where to create a file that calls the functions of my calculator class and ...
3
votes
0answers
51 views

Product's “Layout Update XML” code disappears from the site every 24 hours

I have some products with "Layout Update XML" Design updates (simple XML pointing to a template file; very basic and in the correct format). Every 24 hours after a cache flush, the code vanishes from ...
1
vote
1answer
155 views

Customer Account page title is at the bottom, and margin-bottom is being set to 0 but i cant find where

I'm so close to having this site finished and then this happens. I logged into the customer account section to check all was good and then i was greeted with this... It should look like this... I ...
4
votes
1answer
799 views

Magento 2 Blank Layout Page

I tried to create a new tab in customer edit backend. First i create the app/code/Namespace/Point/view/adminhtml/layout/customer_index_edit.xml <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
0
votes
4answers
905 views

Magento 2 Customer Account Navigation Add Css Class to link not working

XML: <referenceBlock name="customer_account_navigation"> <block class="Magento\Customer\Block\Account\SortLinkInterface" name="customer-account-navigation-account-link"> <...
0
votes
1answer
160 views

How to Change Block class for sales order status history tab

Below is the Block <action method="addTab"> <argument name="name" xsi:type="string">order_history</argument> <argument name="block" ...
2
votes
1answer
973 views

Difference between Extend a layout and Override layout

In Magento2 currently, I override XML file using below way and make required changes. app/design/frontend/Vendor/Theme/Magento_Catalog/layout/default.xml But I have seen in Magento dev docs ...
1
vote
0answers
12 views

how to fetch value from URL and post in form M2

I have product grid in admin panel where I have edit link too. Edit link looks like http://localhost:8888/backend/division/products/productedit/a_id/10/id/26794/ in ui form I need to send this id :...
2
votes
1answer
194 views

Magento 2: Conditionally process layout XML file

I have an XML layout file, specifically customer_account_login.xml, which is processed automatically by Magento and replaces the out-of-the-box copy. In some cases I would like to do this, while in ...
2
votes
2answers
808 views

Magento 2 custom column sorting not working

I have created custom column in Sales -> Order UI Grid. I have added "Profit" column. Which is not related to any database table and not the attribute. This column display just calculation of ...
1
vote
0answers
187 views

Magento 2.2.5: How to create Button in Widget

i'm looking for the way to create Button in Widget I've done this but it throw an error said "Invalid xml type". So i thing that there's no such thing called xsi:type="button" in magento 2 widget. &...
0
votes
1answer
36 views

Magento2 Multisite now loading store specific default_head_block.xml

I have a magento 2.2.3 that I am trying to setup with a Multisite where each store view has a different child theme. Now My workflow is that I work on a local MAMP version of the website I then ...
1
vote
0answers
39 views

Magento 2: Alternative layout for bundle

I need two different layouts for bundles. For this I created an alternative page layout in the page_layout folder. I am able to access the page layout in the backend of the bundle what works like a ...
2
votes
3answers
2k views

Move “Add to Wishlist” Button after “Add to Cart” in Product View

How to move "Add to wishlist" button after "Add to cart"? I try using move but it's just working on the configurable products. I want it to work too on the simple products. Check my ...
0
votes
1answer
272 views

Magento2 Hide Custom Tab based on Condition

I have created custom tab in Magento2 in my Custom module. The code used to make tab was using xml like - <referenceBlock name="product.info.details"> <block class="...
0
votes
1answer
135 views

In checkout when i get to the payment information i get this error. Attention [XML2Array] Error parsing the XML string

This would be the last step in the checkout process. I hit checkout and it would take me to a success page. Right when i hit the button it throws this error. I did a search on the server for what ...