Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
framework
Setup
XmlPersistor.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Framework\Setup
;
7
11
class
XmlPersistor
12
{
19
public
function
persist
(\SimpleXMLElement $simpleXMLElement,
$path
)
20
{
21
$dom = new \DOMDocument(
'1.0'
);
22
$dom->preserveWhiteSpace =
false
;
23
$dom->formatOutput =
true
;
24
$dom->loadXML($simpleXMLElement->asXML());
25
file_put_contents
(
26
$path
,
27
str_replace(
28
' xmlns:xsi="xsi"'
,
//replace namespace, as we do not need it for xsi namespace
29
''
,
30
$dom->saveXML()
31
)
32
);
33
}
34
}
Magento\Framework\Setup\XmlPersistor
Definition:
XmlPersistor.php:11
Magento\Framework\Setup\XmlPersistor\persist
persist(\SimpleXMLElement $simpleXMLElement, $path)
Definition:
XmlPersistor.php:19
Magento\Framework\Setup
Definition:
BackendFrontnameGenerator.php:7
Magento\Framework\Filesystem\Driver\file_put_contents
file_put_contents()
Definition:
http_mock.php:25
$path
$path
Definition:
import_with_filesystem_images.php:14