Questions tagged [system.xml]

Denotes question related to the system.xml module configuration file.

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

How to enable/disable welcome email from admin configuration in store basis

Hi I referred this solution for disabling welcome email and it works perfectly.however i want the around plugin to work only if its enabled from admin backend that too in store basis. I added etc/...
user avatar
  • 1
1 vote
1 answer
45 views

How to get Data from system.xml file

I created system.xml file where seller can select multiple options (e.g Days of the week). Now i need to use that data in checkout page as . Where customer can select one option (e.g any day from ...
user avatar
0 votes
0 answers
33 views

Add multiple image uploader in System Configuration

For single image upload, we are using below code, but I want to upload multiple image so how to do that: <field id="upload_image" translate="label comment" type="image"...
user avatar
2 votes
1 answer
270 views

Magento 2 add & dynamic rows in system config

Is there any way to add & save dynamic rows in magento 2 system config? I want to add the below fields : Name Link Upload image Any help would be appreciated.
user avatar
  • 58
0 votes
0 answers
26 views

System configuration loop fields

Do I need to list different fields for all websites in the system configuration? How can I do this? I have 3 websites. And I want to list different fields with YesNo source. <group id="...
user avatar
0 votes
2 answers
45 views

Disable the Config field after entering data

I am trying to disable the text field in the configuration field once admin has entered the data. I know it can be done via <frontend_model> but in that case the field gets disabled as soon as ...
user avatar
  • 107
0 votes
1 answer
93 views

Magento 2 tree view in Stores->Configuration

I'm starting to try to program in Magento. I have a problem creating a category tree in the configuration of my module. I want to be able to choose a category. More than one. Just like in the photo ...
user avatar
0 votes
1 answer
105 views

How can I add a new group to an existing section Admin Settings

So I'm trying to add a new group called Checkout Gifts inside the section checkout in the tab sales. I was able to add a section to an existing tab but when I tried the same approach to create a new ...
user avatar
  • 137
0 votes
1 answer
44 views

Loading Admin Settings into JS

so I'm trying to add some new configurations to my checkout page, and I added 3 new settings to the admin page, but now I would like to load them to my JS file, but I don't know what to do to achieve ...
user avatar
  • 137
0 votes
1 answer
144 views

Magento 2.4.2: Setting and getting custom config data works fine, but the text field in the admin backend is empty

I am able to set and get config data in a field under General table with the test code. The Magento backend displays the field as the screenshot below shows. The issue is this field is blank, but ...
user avatar
0 votes
1 answer
84 views

Magento 2.4.2: Do I need to override system.xml in my custom module to add a new tab, section, group and field in the admin backend?

I need to set and get config data in Magento backend. I know that it is system.xml under module-backend that I need to add to. I am little confused as to how to override this file in my custom module. ...
user avatar
0 votes
0 answers
32 views

Magento 2 : system config

app/code/Vendor/Paypal/etc/adminhtml/system.xml <?xml version="1.0" ?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation=&...
user avatar
  • 367
0 votes
1 answer
26 views

Dynamic Admin Custom Fields Don't Save When Click Save Config Button

I Create Dynamic Table In Admin Panel, Each Row Contain 5 Fields That Will Be Display As Carousel In Front Page. I Manage To Create It. when I click Add Row Its Adding The Rows To The Table But When I ...
user avatar
0 votes
2 answers
230 views

Custom Admin Button OnClick Add more Group Of Fields to Section

I Created Custom IconSlider Module That Can Be controlled from Store-Configuration. Each slider Have the Same 3 Fields (Name,URL,Image). i added a few groups With that fields But every time i want to ...
user avatar
0 votes
1 answer
35 views

How to check system config field value before used in front end in Magetno 2?

I need to check the config field value before they used in fronted at any where Suppose Ex. customform/general/adminmail, the field i used in many extension so i am check that value befor they used ...
user avatar
0 votes
1 answer
112 views

How can I set custom validation using controller in system config file in Magento 2?

I want to set custom validation on system config file that "accept character do not allow any script tag" only accept like that ex. config/group/field, config/group/field Here is my ...
user avatar
0 votes
1 answer
112 views

Show/Hide the Configuration grid/list/field in magento 2

I am trying to show/hide the password text configuration filed based on the dropdown field and it's working fine & the code as follow. <depends> <field id=&...
user avatar
  • 3,896
0 votes
1 answer
87 views

Magento2.3.5 Disabled dynamic row system field

How can one add a disabled attribute to an input field in dynamic row system ref: https://devdocs.magento.com/guides/v2.4/ext-best-practices/tutorials/dynamic-row-system-config.html What I've tried: $...
user avatar
0 votes
0 answers
91 views

Magento2.3.5 Dynamic Row Add New Column Removes Current Fields

I've added 4 dynamic row while back ref:https://devdocs.magento.com/guides/v2.4/ext-best-practices/tutorials/dynamic-row-system-config.html Now I've added a 5th column but all the row data that was ...
user avatar
0 votes
0 answers
31 views

Save config.xml value on install/upgrade

I have just created system.xml and config.xml for my project - they work ok after implementation: The values don't get written to the database unless I press save in admin though - ran setup:upgrade ...
user avatar
1 vote
1 answer
433 views

Show/Hide configuration field in Magento 2

In Magento 2 if we need hide/show the field in the same group we will fallow as below. <section id="custom_general" translate="label" type="text" sortOrder="0&...
user avatar
  • 3,896
0 votes
1 answer
108 views

System Config Upload File Input Disabled

Here is the content of the system.xml file: <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Config:etc/...
user avatar
1 vote
2 answers
555 views

Magento 2 Custom system config value not showing in custom email template

Able to get values of store phone number but not able to get custom config values(even it is working fine in root file when get custom config value) How to get value for this - {{config path="...
user avatar
  • 1,143
0 votes
2 answers
764 views

Magento 2 - How to allow certain html elements in system.xml config field?

I try to add this HTML (<span style='color:red'>*</span>)to the content of a field with type text. But the html is getting stripped. How can I allow all secure html elements but disallow ...
user avatar
  • 2,403
0 votes
1 answer
933 views

Display Customer Groups Dropdown in admin system configurations in custom module of Magento 2

I want to provide customer group based configuration in my custom group. So need to add customer group multiselect dropdown in system configuration at admin in Magento 2.x
user avatar
0 votes
3 answers
186 views

How to disable custom plugin in admin

I have created a custom module to disable free shipping based on some conditions. I have to used Custom/ShippingRule/Plugin/Magento/Shipping/Model/Shipping.php to do the functionality. It is working ...
user avatar
  • 828
0 votes
1 answer
180 views

magento 2 how to get shipping method in system configuration

system.xml <field id="shippingmethod" translate="label" type="multiselect" sortOrder="20" showInDefault="1" showInWebsite="1" showInStore=...
user avatar
2 votes
1 answer
293 views

How to find config column in core_config_data table?

I want to add values to this field from "core_config_data" table, how do i identify it ? <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
user avatar
3 votes
0 answers
97 views

Add color picker in system.xml in serialized grid in Magento 2

I want to assign the color code to a particular customer group by the system.xml file. I have successfully created the grid, but I am facing difficulty adding the color picker in the color column of ...
user avatar
  • 1,096
1 vote
1 answer
717 views

How to get PDF file URL uploaded in system.xml. Magento 2

I'm trying to upload PDF file via system.xml my code is <?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
user avatar
  • 1,434
0 votes
2 answers
158 views

Get system config data in custom module

I've seen a couple of things about this but I can't seem to get the value I have <field id="template" translate="label" type="select" sortOrder="3" ...
user avatar
  • 346
1 vote
1 answer
171 views

Magento 2 : Fetch system.xml group id in source model

In Magento 2, I want to fetch group id from system.xml in my custom sourceModel But I am unable to find a solution online. Please do let me know if it's possible or not. I know there's an alternate ...
user avatar
0 votes
0 answers
51 views

How to send email admin dynamically when order placed

In this I want to create custom module for Send email to admin from one email sending field to get email id and send email on that id after order placed successfully using event and observer and one ...
user avatar
  • 498
2 votes
1 answer
295 views

Can you redirect CMS page to custom frontend route magento 2.3.5

I am trying to redirect a cms page to a new route which I have created for frontend. I am not sure if we can redirect to the new custom module route frontend with a config in admin area. My aim is I ...
user avatar
1 vote
0 answers
97 views

Magento 2 system configuration image file upload into my custom directory with the size validation

I am working a Magento Extension, as per my requirement I've to upload an image from the system configuration field. I have done the image upload, once the image uploaded the file stored in (root/pub/...
user avatar
  • 1,598
0 votes
1 answer
107 views

how to get html code in config values magento 2

I have created a field in admin configuration .I want to use the value of the field.If the value of the field is <b>test</b> it displays <b>test</b> not as test.how can I get ...
user avatar
0 votes
1 answer
197 views

Magento 2 : Set Dynamic User Define Time for Run cronjob?

We are developing one Extension in which we provide the facility to the user to set his custom time for run corn job. for this functionality, we provide fields in-store configuration like: Custom ...
user avatar
2 votes
2 answers
623 views

Source model issue from system xml in Magento 2

I've created two dropdowns field in the system.xml , both of them have the same options, except that one has an extra option: None. This is the xml: <field id="printing_option" translate="...
user avatar
  • 3,575
1 vote
0 answers
52 views

How can we clone groups like clone field in system.xml in Mageno 2?

In system.xml file, for cloning the fields we use clone_fields and clone_model. Here is the example: <group id="placeholder" translate="label" sortOrder="300" showInDefault="1" showInWebsite="1" ...
user avatar
  • 427
2 votes
2 answers
287 views

Custom system.xml source model, ReflectionException class does not exist

Writing a new module and in my system.xml I can put the following: <field id="environment" translate="label" type="select" showInDefault="1" showInWebsite="1" showInStore="1"> <label>...
user avatar
  • 121
2 votes
0 answers
37 views

Magento 2: How to implement method _saveSection() of vendor\magento\module-config\Controller\Adminhtml\System\Config\Save.php

The definition of function says it further checks the method _saveVendorModule in the current class ($this) for custom logic. Does anyone has used this before to add or override some logic? /** * ...
user avatar
  • 3,572
0 votes
1 answer
1k views

Magento 2.3: system.xml and config.xml: Default values not showing up in the admin

I'm developing a module for Magento 2.3 and can't get default config values to show up in the admin. To the best of my knowledge, I've followed all the documentation I can find. It's kind of driving ...
user avatar
1 vote
1 answer
130 views

What does "clone_fields" and "clone_model" attribute mean in vendor\magento\module-catalog\etc\adminhtml\system.xml?

<group id="placeholder" translate="label" sortOrder="300" showInDefault="1" showInWebsite="1" showInStore="1"> <label>Product Image Placeholders</label> <clone_fields>1&...
user avatar
  • 3,572
0 votes
1 answer
43 views

Can you perform Magento UI_Component Validation with value from store config?

Is it possible to get the minimum text length value from store config system.xml? <field name="mytext" sortOrder="20" formElement="input"> <argument name="data" xsi:type="array"> ...
user avatar
0 votes
1 answer
866 views

How to get only one Specific Country's States/Province in dropdown?

I'm working on Magento 2.3.2, I override a Shipping Method file which is system.xml for adding custom fields. Here it is: <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:...
user avatar
1 vote
1 answer
275 views

Dynamic element in system.xml field

I have a list of elements printed with a field type='checkboxes' but when I try to save only one of the results saved. As a solution to this problem, we tried to print each element with a checkbox ...
user avatar
0 votes
1 answer
264 views

How to Set Store Config (system configuration)

We can get system configuration values using Mage::getStoreConfig($xmlPath); But how can we set such configuration field programatically? I would expect some method like Mage::setStoreConfig($...
user avatar
  • 1,180
0 votes
0 answers
46 views

Magento 2.3 Dynamic comment in system.xml group?

I need a way of adding a group comment that is dynamic, as I need to pass the stores URL (it gets added as a return URL for a 3rd party service) It seems like it used to be possible, using a model ...
user avatar
1 vote
1 answer
330 views

Magento 2: Get value from Cron system.xml

I would like to take the value of the ahead schedule of this system.xml <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:...
user avatar
  • 187
1 vote
1 answer
416 views

How to Validate Comma Seprated Values in Admin Configuration

I want to Add Validation of Comma Separated Values in Admin Configurations I Know How to Add Custom Validation Using Js is just need the Regex (Regular Expression)
user avatar
  • 2,039

1
2 3 4 5 6