Ok, I'm trying to find a way to get the last ending p tag </p> and place a string in front of it.
$string = "<p>Some text</p><p>More text.<p/><p>Even more text.</p>";
$insert = " Here is an insert.";
results need to be:
<p>Some text</p><p>More text.<p/><p>Even more text. Here is an insert.</p>
Help would be greatly appreciated - this has been quite a headache!