PHP Regex. Extract higher level elements from code. Include nested elements
Dibayar semasa penghantaran
I am looking for a PHP developer who can extract higher level elements from code, including nested elements.
Please see the attachment. There are 3 higher level elements: 1 cover and 2 groups. So I need to extract them with nested elements and texts and place into an array. Maybe you should use preg_match_all function.
So, the output must be:
'<!-- wp:cover ... <!-- /wp:cover -->',
'<!-- wp:group ... <!-- /wp:group -->',
'<!-- wp:group ... <!-- /wp:group -->'
Please look into wp:cover element - there is another wp:cover. So, your code must extract the parent wp:cover with children wp:cover. The same is with wp:group elements.
Please, start your message with wp:group to let me know that you've read the description.
ID Projek: #37231754