$pattern = '/<a\s+href=["\']([^"\']+)["\']/i';
$desc_feed = preg_replace($pattern, '<a href="https://www.facebook.com/something"', $block->get_description());
This is the regex I use to filter for URL which works well. However, I just want to target a certain type of URL, namely I just want to replace the entire URL ONLY if it contains a certain substring: //l.face...
(without the dots)
any help appreciated.