How to clean up text with PHP – remove line breaks, paragraphs and tabs and replace with an empty space

For some text, like Meta description tags and excerpts, you may not want to have paragraph formatting, empty lines, breaks in the text. Especially when you are extracting this text automatically to generate the Meta description. This is a simple regular expression to remove line breaks, paragraphs and tabs, and replace them with an empty […]

Posted in Wordpress Tips. No Comments »