In PHP, I have a string like this:
$string = \"user@domain.com MIME-Version: bla bla bla\";
How do i get the email address only? Is there a
Have a look at Regular expressions in PHP.
With regular expressions you can identify any text pattern in a given string. They are incredibly useful. So even though you can stick with copy-pasting a code snippet from another answer for now, you should consider digging a little more into it.
It can be a bit complex at first but it's definitely worth the effort.