[TASK] Mark array2xml_cs() as deprecated, use array2xml() instead
[Packages/TYPO3.CMS.git] / typo3 / sysext / core / Documentation / Changelog / master / Deprecation-75371-Array2xml_cs.rst
1 ==================================
2 Deprecation: #75371 - array2xml_cs
3 ==================================
4
5 Description
6 ===========
7
8 The method :php:`GeneralUtility::array2xml_cs()` has been marked as deprecated.
9
10
11 Impact
12 ======
13
14 Using the method :php:`GeneralUtility::array2xml_cs()` will trigger a deprecation log entry.
15
16
17 Affected Installations
18 ======================
19
20 All installations with third party extensions using this method are affected.
21
22
23 Migration
24 =========
25
26 Use :php:`GeneralUtility::array2xml()` instead. The XML declaration must be written manually.
27
28 Example code:
29 .. code-block:: php
30
31 // Deprecated
32 $bodyText = GeneralUtility::array2xml_cs($array, 'phparray');
33
34 // Migrated
35 $bodyText = '<?xml version="1.0" encoding="utf-8" standalone="yes" ?>' . LF . GeneralUtility::array2xml($array, '', 0, 'phparray');