Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [xml]

Denotes questions about XML files and XML processing.

1
vote
2answers
70 views

Magento 2 : How to convert class object to string using observer?

I am getting error during to save order data to xml format using observer.. Recoverable Error: Object of class Magento\Sales\Model\Order\Item\Interceptor could not be converted to string in ...
0
votes
3answers
221 views

Magento 2 - Add custom js in admin product edit

I want to add custom js in product edit page (Admin) Is it ok to add it in some xml or is there any other way to do it? If it is xml, which XML do I need to work on?
0
votes
1answer
27 views

magento 1.9 override core block template

I edited these files but I cannot override the default.phtml file, it doesn't work, what's wrong with that? Config.xml <?xml version="1.0" encoding="UTF-8"?> <config> <modules&...
0
votes
1answer
31 views

How can we populate the default shipping address country and zipcode in cart page in magento 2 for logged in customers?

Can we populate the default country and postcode for the logged in users using their default shipping address of the customer to get shipping estimates?
1
vote
1answer
15 views

Editing bundle product page

i'm still new in magento 2 and i want to edit layout of bundle product page of magento 2, so i extend xml file of magento 2 from module-bundle. i create folder Magento_Bundle/layout/...
2
votes
1answer
244 views

How to parse XML - simplexml_load_string returns error “parser error : StartTag: invalid element name”

I am trying to parse XML to array in my custom module in Magento 2.2.7. Community version (free) I am loading Helper\Data through Block element and this is "working". This is my Helper\Data.php <...
0
votes
1answer
29 views

Magento 2: Errors displaying on setting devolper mode

On setting developer mode this error is displaying want to find the files which are causing this error what should I do remove this error. [2019-02-14 12:58:34] main.INFO: Cache file with merged ...
0
votes
1answer
69 views

Magnifier is not showing

Magnifier is not showing. Option enable set to true. Settings in my theme: Vendor/MyTheme/etc/view.xml <var name="magnifier"> <var name="fullscreenzoom">10</var> <!-- Zoom ...
0
votes
2answers
23 views

Magento 2 describe attrubute property used in Plugin method

I am trying to create a simple module and I can't find the propose of the attribute name and type inside the tag type and plugin in di.xml. can anyone describe attribute name used in plugin? <?...
0
votes
1answer
53 views

Solve warning “User Agent Exception override product and CMS pages rules”

I'm Trying to create a dynamic grid containing multiple fields using this code in my ui_component <fieldset name="multi_answer"> <settings> <collapsible>true</collapsible>...
1
vote
1answer
56 views

User agent exceptions override product and CMS pages rules

I am trying to implement this dynamic grid/ to add multiple records it is working fine but I am getting this "User agent exceptions override product and CMS pages rules." all over it any idea how to ...
0
votes
0answers
57 views

Export Category name in xml feed Magento 1.9.2

I have the script below for exporting product xml feed for magento 1.9.2 The problem is that I cannot export the category name for each product The scipt is: require 'app/Mage.php'; Mage::app(); $...
0
votes
1answer
71 views

magento 2 how to edit custom header in site which path i can edit

here is the code for custom header <div class="message global demo"> <div class="content"> <p>This is demo store. No orders will be fulfilled.</p> ...
0
votes
1answer
95 views

Magento 1.9 Override zend lib xml file?

I followed this tutorial: https://www.damianculotta.com.ar/magento/bug-en-los-locales-es-en-magento-1-y-2/ which suggested to override this file: src/lib/Zend/Locale/Data/es_419.xml. I created the new ...
0
votes
1answer
718 views

Exception #0 (Exception): Notice: Undefined index: id in Iterator

I'm tryingto extend Magento2 Adminhtml with some custom nodes, which has worked good so far. What I'm trying to do now is to figure out how this error is happening: Exception #0 (Exception): Notice: ...
0
votes
0answers
33 views

Magento Amasty FPC and Dynamic Content

We have Amasty FPC and want to use their hole punch method for Dynamic Content but I’m a little confused on the XML configuration file. Their is two methods which have the block exclusions - one is ...
1
vote
0answers
20 views

Generate xml php code problem

I am using a php script to generate an xml from my magento 1.9 to a comparison engine. I have a field in the engine called mpn which need to be filled from my product's SKUs $aData['id']=$iProduct; $...
0
votes
0answers
15 views

Magento2 make logo inline with navigation

To make the logo and nav sections inline is it better to move the logo into the nav or the nav into the header?
0
votes
2answers
124 views

How to override order sales model in magento 1.9

I have stuck with this. I am trying to override sales/ order model _saveafter function with my custom module. I have the following code \app\code\local\Rkt\SalesNew\etc\config.xml <modules> ...
0
votes
1answer
20 views

add a section/tab on the right section of all categories in front end magento2

Hi there I want to add my custom section/tab on the right section of all the categories for getting a clear idea I am attaching this image This is the men section I want to add the same custom tab ...
0
votes
0answers
15 views

Magento2 If I move containers with XML it kills css

I applied custom css to my navigation bar. Then when I moved the nav bar into the header via xml my css was no longer working. Why is that? The correct css is in the section.
0
votes
0answers
267 views

Magento2 set image size in etc/view.xml

I have this XML to set my image sizes for both related products and my catalog widget on my home page. The Related Products portion works but the home page one doesn't. <media> <images ...
0
votes
0answers
54 views

Move element is not working as expected in magento 2.1

In category_catelog_view.xml I need to move a custom layered navigation above the product grid. I tried all of the listed below <move element="custom.left.layered_nav" destination="content" before=...
0
votes
1answer
213 views

Element 'block', attribute 'remove': The attribute 'remove' is not allowed. Line: 745

I'm getting this error when I hit the front end. Couldn't able to find any solution regarding this. 1 exception(s): Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'block'...
0
votes
0answers
65 views

Magento 2 on mobile display layered navigation before products

In default Magento theme, on the category page, the layered navigation is at the left column, and products in the main. This is OK. However on mobile, it first displays the products, and after the ...
0
votes
0answers
28 views

Change Module position in xml

I used a module Product Videos in Magento 1. I like to show a videos in description tab ? It is possible ?
0
votes
0answers
36 views

In mftf, popup elements are not getting identified

In Test folder xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd"> <...
0
votes
1answer
54 views

error when creating a new container inside page.wrapper in magento2

I'm trying to create a container inside page.wrapper to contain some custom blocks for my checkout page. When I try the following in app/design/frontend/MyTheme/myname/Magento_Theme/layout/...
0
votes
0answers
49 views

XML product feed category problem

I have written a php script so I can produce for my Magento 1.9.3.8 an xml product feed to send my products to another price comparison site. I have a problem with the category path of my products ...
1
vote
1answer
156 views

Magento 2 How to disable admin menu based on configuration?

xcz I want to hide my custom module menu based on configuration. If in configuration it set to "yes" then the menu should display and if set to "no" then menu should not appear at admin. I have ...
1
vote
1answer
199 views

Magento 2 move reviews form inside list.phtml file

By default magento 2 review structure is like this - /templates/review.phtml and inside it you have - /product/view/list.phtml and Magento_Review/templates/form.phtml files. form.phtml file is ...
0
votes
0answers
22 views

Magento2 Functional Testing Framework (MFTF) - URL not redirecting properly

I want to redirect below page - <amOnPage url="admin/system_config/edit/section/adminconf/" stepKey="navigateToIncommCartTimeout"/> But it is redirecting only admin/system_config/edit/...
0
votes
2answers
223 views

Magento2.2.5 change create account link in top right header

I want to change the URL of the "create An account" link that is on the top right of the site. I want the link to instead of being customer/account/create/ I want it to be customer/account/login I ...
0
votes
0answers
25 views

Override function from grouped.php

I am changing the table for a grouped product. I have overridden the grouped.phtml file to make changes. But I need to override the function: getAssociatedProducts($product) // Grouped.php Because ...
1
vote
0answers
52 views

What is the purpose of validation.xml file in Magento 2?

What is the purpose of validation.xml file in Magento 2? When and where do we use them ? I see there are couple of validation.xml files in Magento 2 directory. For example: vendor/magento/module-...
0
votes
1answer
45 views

Magento 2 - what event should I observe to change/intercept the calculation of subtotals on Cart

I am using Magento 2. I made an observer that observes anytime a new item is added to the cart. The observer works properly, I also managed to create a single product discount with this observer, ...
0
votes
3answers
105 views

Magento 2 Add block before another block using XML

I want to move minicart block to top.links block. This did the trick for me: <move element="minicart" destination="top.links" /> Now, I added a custom block with custom .phtml file to the top....
0
votes
1answer
37 views

Sales order history : remove tab

In xml, how can I remove tab of order in sales/order/history? Can't find the referenceBlock I just need to remove this tab, not the link. To be precise, I'm using an API that will replace this table. ...
1
vote
1answer
16 views

Adding a nav item via XML puts it in the UL but not the correct css classes. How can I add css in my xml?

<block class="Magento\Framework\View\Element\Html\Link\Current" name="nav.sitehome"> <arguments> <argument name="label" xsi:type="string">Link Name</argument> <argument ...
0
votes
1answer
212 views

Magento 2 - Move Block Not Working

I've created a faqs.xml for a bespoke page template and this is my code: <layout xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/...
2
votes
1answer
136 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
63 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
118 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
72 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\...
0
votes
0answers
14 views

Magento 2.2.5 Conflict when deleting links from the customer account page

When deleting the following links, the block-wishlist-management block is deleted as well when checking the Wishlists on the customer account space. Why? : <referenceBlock name="customer-...
2
votes
1answer
65 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
140 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
197 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
69 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
0answers
49 views

call breadcrumbs block twice in page.xml magento 1.9

I am trying to call breadcrumbs.phtml file twice through page.xml file. In page.xml breadcrumbs are added here <block type="page/html" name="root" output="toHtml" template="page/3columns.phtml">...