Php extract all the mailbox addresses in the text, or all the mailbox addresses in a string, for example, my text is: the Chinese character is scddtest001@qq.comasdatest002 @ qq.com after you amtest009@aa.com matching results should be test001@qq.comtest002 @ qq. comtest009 @... php extracts all email addresses in the text, or all email addresses in a string
For example, my text is:
Chinese character is scdd test001@qq.com asda test002@qq.com after you am test009@aa.com
The matching result should be
Test001@qq.com
Test002@qq.com
Test009@aa.com
My code is as follows;
Currently only one Email address can be matched to the test001@qq.com, the other two currently do not match, to use greedy pattern match?
Please advise !!
Reply content:Php extracts all email addresses in the text, or all email addresses in a string
For example, my text is:
Chinese character is scdd test001@qq.com asda test002@qq.com after you am test009@aa.com
The matching result should be
Test001@qq.com
Test002@qq.com
Test009@aa.com
My code is as follows;
Currently only one Email address can be matched to the test001@qq.com, the other two currently do not match, to use greedy pattern match?
Please advise !!
Problem solved
Use preg_match_all