[MGNLFORUM-102] Support minimal code formatting Created: 18/Aug/10  Updated: 02/Dec/13  Resolved: 20/Aug/10

Status: Closed
Project: Forum (closed)
Component/s: None
Affects Version/s: None
Fix Version/s: 4.0 ? (rewrite)

Type: Task Priority: Major
Reporter: Fabrizio Giustina Assignee: Fabrizio Giustina
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Template:
Acceptance criteria:
Empty
Task DoR:
Empty
Date of First Response:

 Description   

we need code formatting in posts, at least for auto-linking and posting of code (nb actually we don't have a way to add newlines too).
We discussed about it and a rich html editor like fckedit is not wanted, due to possible security/XSS problems it may introduce. A good solution could be using BBcode, commonly used in forums and easy to implement.



 Comments   
Comment by Fabrizio Giustina [ 18/Aug/10 ]

Added BB code formatting using a snippet coming from javabb with an apache license: http://kickjava.com/src/org/javabb/bbcode/ProcessBBCode.java.htm

there is no distribution with this class and I couldn't find anything better, so it should be ok to include it in sources, the original license is kept below the magnolia one in the code.

Comment by Fabrizio Giustina [ 20/Aug/10 ]

added a simple bbcode editor with few tags (quote, code, bold...) and escaped all the html content.

Comment by Christoph Meier [ 02/Dec/13 ]

closed, since it was resolved a long time ago

Generated at Mon Feb 12 02:00:44 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.