<textarea><?
if ($result[0]->resume) echo str_replace("'", ''', htmlentities(preg_replace('/<(br|p)[\s\t]*\/?>/i', "\n", $result[0]->resume)))
?></textarea>
I am trying to strip out all occurrences of <br> or <p> tags within inputted text inside <textarea> tags. This, for some bizarre reason, sometimes works and sometimes doesn't work, it will strip out these tags for one person's resume; it will leave them untouched in another resume.
Does anyone know of a consistent means of stripping these tags out and replacing them with newline/line-feed instead?
Thanx
Phil