Questions tagged [xml]

Denotes questions about XML files and XML processing.

332 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
2
votes
0answers
494 views

Warning: simplexml_load_string(): lib/Varien/Simplexml/Config.php on line 383

I know this is a very general error but i need help getting it fixed. I believe there is an extension with invalid XML and that's the cause of this error. So if i have a syntax error somewhere in an ...
2
votes
0answers
752 views

Magento 2 name attribute shows empty when creating custom fields on product page

When i try to add new fields to product creationg form in Magento 2 the html name attribute shows up empty, I tried more or less everything and by everything i mean: 1) Adding the custom field i ...
2
votes
1answer
460 views

Magento 2 : Debug Xml

I need to work with xml and something doesn't work same it's always. Is there a way to see errors in xml syntax, calls, or something. I don't see nothing in Magento's log, or even in apache's log. ...
2
votes
1answer
530 views

Magento 2 - Override an xml file defined in the etc folder in a theme?

I am attempting to override the email templates for the Aheadworks_Giftcard extension. It seems that the email templates are defined in a xml file in the etc directory called sample_email_templates....
2
votes
4answers
1k views

Can't remove layout blocks. (Magento 2)

Information: I'm using Magento 2.1 on CentOS Linux, my theme is a child of the built-in Luma theme. When the theme I made is active, I want some blocks to be removed. Let's say I want to remove the ...
2
votes
0answers
24 views

How to change the /contact router to something else?

By default Magento2 offers a contact form. This can be reached under http://domain.tld/mage2orwhatever/contact. But we want to have the router to be translated, in our case it'd be kontakt. How can ...
2
votes
0answers
280 views

Move a specific widget to another container via XML

I want to move a specific widget, lets name it demoWidget to the top container, when it is on a site. How can I achieve this? I've thought about this solution, but have no idea how to do it: give ...
2
votes
1answer
552 views

Magento 2: How to move recently viewed

Having problems working out how to move the recently viewed block. I want it to sit above the details/review tabs but can't work out how to move it in the xml?
2
votes
0answers
48 views

How do I specify structure of all child elements of a node in XSD where the node names vary?

I am building Magento 1 XSDs (XML Schema Definitions). Magento very often uses node names as a unique identifier for a node in XML. For example: <config> <events> <...
2
votes
2answers
1k views

Magento 2. Change column sort order

Columns in magento 2 has item sort order: <item name="sortOrder" xsi:type="number">44</item> But it doesn't change the column order. What need I to do to change columns order?
2
votes
0answers
326 views

Magento 2 - make head element translatable

I wish to translate the "Forgot Your Password" string which is created as a head and body element on the Forgotten password page. I found that this string is generated via xml in: Magento_Customer/...
2
votes
1answer
87 views

Inserting blocks into custom places

In Magento 1 I can edit local.xml like so: <default> <reference name="root"> <block type="core/template" name="above_main" template="page/html/banner.phtml" /> </...
1
vote
0answers
10 views

How to move the block under the sidebar in the payment step of checkout

I have a block that I display on the checkout at the bottom of the page <referenceContainer name="page.wrapper"> <block class="Magento\Framework\View\Element\Template" name="...
1
vote
0answers
18 views

add custom banner on specific product view page

I tried to add a banner for a specific product but when I looked for the options, I can add in the content of the product, but I need the banner on the top of the specific product view page. Is there'...
1
vote
0answers
16 views

How to change driver between amqp and db

We have an extension that can make use of either MySQL driver db or RabbitMQ amqp. The drive is mentioned on these files: etc/queue_consumer.xml etc/queue_publisher.xml etc/queue_topology.xml https:...
1
vote
0answers
19 views

How to control block XML cache via admin?

I've created a condition in my admin panel to enable or disable a feature in my module. In my XML I used the ifconfig to check if it's enabled or disabled. I want to disable the cache in the entire ...
1
vote
1answer
24 views

Magento2 - How to create sitemap pro-grammatically with custom script

I want to create sitemap pro-grammatically using script, any one have idea, to create sitemap using API or another way...
1
vote
1answer
46 views

Error of layout xml : Element 'update': This element is not expected

I'm upgrading a theme from 2.2.x to .2.3 there are so many xml in this theme have the following directive <?xml version="1.0"?> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-...
1
vote
0answers
20 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 ...
1
vote
1answer
195 views

Exception in Magento log: the element can't have a child

I found the following errors in the exception.log and debug.log files in /var/log folder: [2019-12-17 16:23:05] main.CRITICAL: The element "product.info.options" can't have a child because "product....
1
vote
1answer
175 views

Move bundle options via XML - Magento 2

I've tried absolutely everything I can think of to move the bundle options but for some reason they won't move. When you click the customize and add to cart button it's those options that I want to ...
1
vote
1answer
65 views

How to disable button url in Magento 2?

I tried to put # places of the url, but the url still works and e.stopImmediatePropagation () with js also didn't help. Is there any way to do this through xml or otherwise? Thanks <item name="...
1
vote
0answers
80 views

Magento 2.3.2 LayoutXML Update remove canonical

Under Stores > Configuration > Catalog > Catalog, We have "Use Canonical Link Meta Tag For Categories" set to "Yes" There are a couple of category pages that we want to edit the Canonical Link for. I ...
1
vote
0answers
40 views

template is not working magento 2 admin customer_index_edit

I am calling a js function form this file current.phtml like this <script type="text/javascript"> require([ 'jquery', 'jquery/ui'], function($){ $(document).ready(function($) { updateAjax()...
1
vote
0answers
31 views

Override Api xml Magento1

i made changes in app/code/core/Mage/Customer/etc/api2.xml now i want to override this xml in my local module how i do
1
vote
0answers
230 views

magento dev:urn-catalog:generate command fails to detect secret file

I'm running the following command "magento dev:urn-catalog:generate .idea/misc.xml " to use the functionality of Magento 2 to automatically resolve all my URN's so PhpStorm will stop giving me ...
1
vote
2answers
65 views

Magento 2.3 How to override the custom theme's etc/layouts.xml file in recommended way?

There is, in a theme that I bought a layout.xml file that is used in the backoffice to hydrat a select element (that allows you to switch between 5 layouts). app/code/CompanyTheme/LayoutSwitcher/etc/...
1
vote
1answer
35 views

Add custom block under long description (product.info.description)

I'd like to add a custom block in description tab just after long description field. I Tried <referenceBlock name="product.info.description"> <block class="Magento\Catalog\Block\Product\...
1
vote
1answer
68 views

Remove class on div from empty.xml layout

I am running Magento 2.2. I have custom HTML I want to add to a CMS page. After navigating to the page where this HTML resides, the content is automatically displayed inside a div with class page-...
1
vote
1answer
548 views

How to create page in customer account section Magento 2

I want to create new page and link to => HISTORY how i can do this?? where I can add a new link?
1
vote
1answer
40 views

When I switch the mode default to developer of magento2.2.3 then got this error Element 'count': This element is not expected

Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'count': This element is not expected. Expected is ( argument ). Line: 1077
1
vote
0answers
56 views

How to add amazon and paypal buttons in the one page checkout module in magento 2?

We have to display Amazon button as a separate block in the checkout page, how can we achieve this?
1
vote
0answers
82 views

Magento 2 - display custom product details tab conditionally & as an URL

I want to create a custom product detail tab "Q&A" and only display the tab when there is an Q&A questions exist for the product, and the tab will be the hyperlink to the FAQ page ( for ...
1
vote
0answers
58 views

Magetno 2 get soap api as a xml format

Below is soaporderapi.php created root folder.It is working fine getting order responce but i need to show responce as xml format <?php error_reporting(E_ALL); ini_set('display_errors', 1); ...
1
vote
1answer
22 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/...
1
vote
0answers
40 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; $...
1
vote
0answers
151 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 ...
1
vote
2answers
883 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 : "...
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 :...
1
vote
0answers
234 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. &...
1
vote
0answers
53 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 ...
1
vote
0answers
174 views

Adding a widget into a tab - Magento 2

When you add a new widget you can specify a layout update container. I want to create a custom container that inserts the widget into a tab on the product page. If the tab is empty then hide it. I ...
1
vote
1answer
329 views

Moving grouped product table

I want to move the grouped.phtml table from next to the product image to underneath the image/short description within its own row. So it sits above the description/review tabs. How would it be best ...
1
vote
0answers
28 views

Remove/Unset content of CMS page

I have created a custom module which shows some custom product listing and banner data. I have created a system setting to set those things in homepage or use default one. Now what i want if admin ...
1
vote
0answers
64 views

ifconfig does not work in <css /> tags in Magento 2

ifconfig does not work in <css /> tags in Magento 2. 0 (Magento\Framework\Config\Dom\ValidationException): Element 'css', attribute 'ifconfig': <page xmlns:xsi="http://www.w3.org/2001/...
1
vote
0answers
227 views

Magento 2: How to add custom attribute in an admin field?

I created a new field using the file system.xml, but I need to add a custom attribute, for example, data-mycustomattr="true". You can see an example on this image below, the console shows a custom ...
1
vote
0answers
37 views

Toggle data in xml for ui_configuration

I want to be able to enable/disable the following ui_configuration fieldset via configuration conditions. Much like an ifconfig. I know I can provide a boolean item named 'disabled' in ordered to ...
1
vote
2answers
1k views

Any change to default.xml breaks homepage layout

Fairly new to Magento 2. Working from a cloned version of another site and trying to make simple, cosmetic changes to the custom theme homepage here: app/design/frontend/Vendor/Theme/Magento_Theme/...
1
vote
1answer
113 views

Magento 2.1.7 custom module UpgradeSchema not adding column

I'm not able to add new column to existing table UpgradeSchema.php: namespace Company\Module\Setup; use Magento\Framework\Setup\UpgradeSchemaInterface; use Magento\Framework\Setup\...
1
vote
1answer
201 views

M2 Can't add new Checkout Step

I'm following the Magento dev docs Add a new checkout step how to guide. But I get the following error in my browser console once I go to the checkout... GET http://example.test/checkout/...

1
2
3 4 5
7