File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes JForum and the fly likes localize the citation block Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Java Interview Guide this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Products » JForum
Bookmark "localize the citation block" Watch "localize the citation block" New topic

localize the citation block

Migrated From
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Hi, I am trying to localize jforum to Chinese, now I have problem in replacing citation block

e.g. I want to localize "xxx wrote". I need to replace the bbcode specified in bb_config.

Can any one told me how to do it? Should I use ${I18n.getMessage("PostShow.wrote")}?

thank you for the help.
[originally posted on by seaman]
Migrated From
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I'm not sure that you can do that will the bb_code stuff. This is basically a RegEx pre-processor of the information stored in the database. This is then fed into the templates as just the text of the related object. So you can't use any FreeMarker code in this.. unless Freemarker has some sort of "eval" statement to process template info from data objects.

You may have to add this functionality to the BBCode class. E.g., search for an I18n function and do the replacement there.
[originally posted on by monroe]
I agree. Here's the link:
subject: localize the citation block
It's not a secret anymore!