📜  php 从字符串中提取电子邮件地址 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:57.107000             🧑  作者: Mango

代码示例1
';
    $pattern = '/[a-z0-9_\-\+\.]+@[a-z0-9\-]+\.([a-z]{2,4})(?:\.[a-z]{2})?/i';
    preg_match_all($pattern, $string, $matches);
    var_dump($matches[0]);
?>