çıpadaki mailto ayıklamak için preg_match

0 Cevap php

Ben regex ile mailto öznitelik ile bir çıpa e-posta adresi almak gerekiyor.

Bu desen: (.*)<a\s(.*?)(.*)\s*href\=['"]mailto:([-a-z0-9_]+)@([a-z0-9-]+).([a-z]+)['"]>(.*)</a>(.*)

PHP ile çalışmıyor olsa regex antrenörü İşleri.

Kod:

preg_match("'(.*)<a (.*?)(.*) *href\=['\"]mailto:([-a-z0-9_]+)@([a-z0-9-]+).([a-z]+)['\"]>(.*)</a>(.*)'si", "<a href=\"mailto:someemail@ohio.com\"">Some email</a>", $matches);

print_r($matches);

Peki neden php çalışmak doenst?

0 Cevap