أنشئ حسابًا أو سجّل الدخول للانضمام إلى مجتمعك المهني.
Try this:
(.|\n)*
In regular expressions, the dot or period is one of the most commonly used metacharacters. Unfortunately, it is also the most commonly misused metacharacter.
The dot matches a single character, without caring what that character is. The only exception are line break characters. In all regex flavors discussed in this tutorial, the dot does not match line breaks by default.
the correct REGX
.*\\r\\n
Use the "s" modifier
preg_match('/.*/s', $text, $match);