Skip to content

Commit 04de4c5

Browse files
committed
Merge branch '7.4' into 8.0
* 7.4: [Serializer] Add CDATA_WRAPPING_NAME_PATTERN support to XmlEncoder
2 parents 0bc99d0 + a3ab3af commit 04de4c5

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

serializer/encoders.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,10 @@ These are the options available on the :ref:`serializer context <serializer-cont
198198
``cdata_wrapping_pattern`` (default: ``/[<>&]/``)
199199
A regular expression pattern to determine if a value should be wrapped
200200
in a CDATA section.
201+
``cdata_wrapping_name_pattern`` (default: ``false``)
202+
A regular expression pattern that defines the names of fields whose values
203+
should always be wrapped in a CDATA section, even if their contents don't
204+
require it. Example: ``'/(firstname|lastname)/'``
201205
``ignore_empty_attributes`` (default: ``false``)
202206
If set to true, ignores all attributes with empty values in the generated XML
203207

0 commit comments

Comments
 (0)