Projects ⇒ Bugs ⇒ #579: Parsing HTML in newsletter / Forums ⇒ CPG Dragonfly™ CMS
Bug #579 Parsing HTML in newsletter / Forums
Project: Dragonfly 9.0.3 -> 9.3 Category: Output Control
Submitted: Tuesday, July 05, 2005 (12:14:18) Modified: Thursday, November 02, 2006 (07:37:22)
Status: Closed Assigned to:
PHP Version: 4.3.9 HTTPD Server: Apache 2.0
Votes: 3
Vote results:
Avg. Score: 4.3 ± 0.9 Reproduced: 2 of 2 (100.0%)
Same PHP Version: 0 (0.0%) Same HTTPD Server: 1 (50.0%)

View/Vote Add Comment

by: safecracker4hire
HTML/linebreaks are not being properly parsed in the newsletter and Forums modules. nbbcode.php is failing to add linebreaks to anything that contains HTML as the 'content' that is being parsed is simply returned if there is a '<' character match.

See this post for a suggested fix -->

Reproduce code:
admin/modules/newsletter.php CVS 9.11

modules/Forums/viewtopic.php CVS 9.15

Expected result:
Linebreaks should be parsed, regardless if the content/post contains bbcode/HTML or nothing. Linebreaks are added when bbcode is used, or nothing, but not when using HTML. However, simply adding linebreaks when HTML is used will produce more linebreaks than expected, and in add spots (such as between table/list tags, etc.). The content that is being parsed also needs to have br tags striped from these locations.

Actual result:
Newsletter is recieved like so;

Hello, line1 line2 line3 Kyle Best Regards, Staff We sent you this message because you have selected to receive newsletters from our site You can choose to unsubscribe from our mailings at any time by following this link If you would like further assistance, please send an email to our administrator

(link and administrator are both hyperlinked)
by: NanoCaiordo
This bug has been fixed in the CVS.

Snapshots of the sources are packaged every 6 hours; this change
will be in the next snapshot. You can grab the snapshot at the
Downloads section.

Thank you for the report, and for helping us to make Dragonfly 9.0.3 -> 9.1 better.
User Info

Welcome Anonymous


Support for DragonflyCMS in a other languages: