The following string contains multiple tags. I want to match the contents of each of the with a pattern, and if it matches, I want
https://regex101.com/r/nE5pT1/1
$str = "para 1نص عربي أو فارسيpara3"; $result = preg_replace("/()[\\x{0590}-\\x{05ff}\\x{0600}-\\x{06ff}]/u", "", $str, 1);
para 1
نص عربي أو فارسي
para3
)[\\x{0590}-\\x{05ff}\\x{0600}-\\x{06ff}]/u", "
", $str, 1);