Nice, but why do you use <p/>? That's equivalent to <p></p>, thus inserting an empty paragraph before each line, which sounds rather nonsensical to me.
If you try to be correct about p nesting, then write $_ = "<p>$_</p>" instead.
Or use <br /> instead.
Comment on Re^2: Substitution inside tags, as 1 line