I have the following code which is an extract from a an email message stored in a variable:
$string = '<td colspan=3D"2"><span style=3D"display: none;">CORRES
PONDANCE_ID:4</=
span> <span style=3D"display: none;">CONFIRMATION_NUMBER:9986337900</s=
pan></td><td colspan=3D"2"><span style=3D"display: none;">CORRESPO
NDANCE_ID:4</=
span> <span style=3D"display: none;">CONFIRMATION_NUMBER:9986337900</s=
pan></td>';
preg_match('/CORRESPONDANCE_ID:([0-9]+)/', $string, $id_matches);
print_r($id_matches);
I can't figure out a way to match CORRESPONDANCE_ID or the number in the subpattern if there is a newline that splits the pattern in the string that is being searched.
I have tried using the x and s modifiers at the end of the pattern but to no avail.
Can anyone please help me accomplish this? Thank you!!