Find the regular match of P tags and match the content of the first segment & lt ;? Php $ body & nbsp; & lt; p & nbsp; aligncenter & gt; & lt; embed & nbsp; typeapplicationx-shockwave-flash & nbsp; & nbsp; srchttp: find the regular match of P tags, match the content of the first segment
$ Body ='
The Kaiyuan railway station in Yunnan
Recently, we are looking for our own parents. If you recognize the children in the video, contact the Kaiyuan railway branch: 0873-3132158.
A few days ago, I checked and moved to multiple locations. with the assistance of the Jinan and Nanchang railway police and public security authorities in Yunnan, Fujian, and Shandong, I successfully detected a child trafficking case.
';
Preg_match_all ("/ ] *> ([^ \ <| \>] *) <\/P>/is ", $ body, $ matchs1 );
Print_r ($ matchs1 );
?>
Expected output
------ Solution ----------------------
Preg_match_all ("/ ] *> \ S *. * \ s * <\/p>/isU ", $ body, $ matchs1 );
------ Solution ----------------------
Preg_match ("/ ] +>/Is ", $ body, $ matchs1 );
Print_r ($ matchs1 );