ParagraphFormat is not XHTML Safe
I just noticed that the ParagraphFormat tag is not XHTML safe. It inserts unclosed
<P> tags for line breaks. I posted a comment on the live docs about this, so hopefully they will add an optional argument to have it generate XHTML output. Here's a function you can use in the meantime:
<cffunction name="XHTMLParagraphFormat" returntype="string" output="false"> <cfargument name="str" required="true" type="string"> <cfreturn REReplace(arguments.str, "\r+\n\r+\n", "<br /><br />", "ALL")> </cffunction>
Like this? Follow me ↯Tweet Follow @pfreitag
ParagraphFormat is not XHTML Safe was first published on May 06, 2005.
The FuseGuard Web Application Firewall for ColdFusion & CFML is a high performance, customizable engine that blocks various attacks against your ColdFusion applications.