#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "<wp:postmeta>[\s\S]*?</wp:postmeta>"
Local $sString = "<wp:postmeta><wp:meta_key>_edit_last</wp:meta_key><wp:meta_value><![CDATA[2]]></wp:meta_value></wp:postmeta>" & @CRLF & _
"" & @CRLF & _
"<wp:postmeta><wp:meta_key>seo_follow</wp:meta_key><wp:meta_value><![CDATA[false]]></wp:meta_value></wp:postmeta>" & @CRLF & _
"" & @CRLF & _
"<wp:postmeta>" & @CRLF & _
" <wp:meta_key>seo_noindex</wp:meta_key>" & @CRLF & _
" <wp:meta_value><![CDATA[false]]></wp:meta_value>" & @CRLF & _
" </wp:postmeta>" & @CRLF & _
"<wp:postmeta>" & @CRLF & _
"<wp:meta_key>_yoast_wpseo_focuskw</wp:meta_key>" & @CRLF & _
" <wp:meta_value><![CDATA[services de proximité, transports de marchandises]]></wp:meta_value>" & @CRLF & _
"</wp:postmeta>" & @CRLF & _
"<wp:postmeta>" & @CRLF & _
" <wp:meta_key>_yoast_wpseo_title</wp:meta_key>" & @CRLF & _
" <wp:meta_value><![CDATA[]]></wp:meta_value>" & @CRLF & _
"</wp:postmeta>" & @CRLF & _
"<wp:postmeta>" & @CRLF & _
" <wp:meta_key>_yoast_wpseo_metadesc</wp:meta_key>" & @CRLF & _
" <wp:meta_value><![CDATA[]]></wp:meta_value>" & @CRLF & _
"</wp:postmeta>"
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYGLOBALFULLMATCH)
Local $aFullArray[0]
For $i = 0 To UBound($aArray) -1
_ArrayConcatenate($aFullArray, $aArray[$i])
Next
$aArray = $aFullArray
; Present the entire match result
_ArrayDisplay($aArray, "Result")
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm