[Solved] remove all text before and after ‘[img id=”123″ align=”left”]’this and get this imageid and also remove the rest part of this stringi


You need to assign the result of preg_replace to a variable:

$result = preg_replace($patterns, $replacements, $Story_Textarea);
echo $result; // prints 55 with your sample text.

solved remove all text before and after ‘[img id=”123″ align=”left”]’this and get this imageid and also remove the rest part of this stringi