The new release brings some cool new features for the Web Content portlet (previously known as Journal portlet), here are some of them:
1. Repeatable Structure fields
Sometimes, while creating a Structure, we can't predict how many fields of a certain type a Web Content entry will need. Now, for each row in a Structure, there is a Repeatable check box:
If I check this checkbox, I can add as many "repeatable-field" as I want while creating my Web Content entry, I just need to click on the plus icon:
Here's the template that I created to list all "repeatable-field", to get all the values I just need to call $repeatable-field.getSiblings() and iterate over them:
And here's the result:
2. Print feature
Go to Web Content Display configuration, click on "Enable Print", a printer icon will appear just below the Web Content Display portlet, when you click on the printer icon, a pop-up shows up the content in a printer-friendly version. But before that, the template being used needs something like:
#if ($viewMode == "view")
Displaying content normally.
#elseif ($viewMode == "print")
Displaying the content in a printer friendly fashion.
3. Web Content conversion to PDF, ODT, DOC...
We have this feature for a long time for Wiki and Document Library, we extended it so Web Content entries can be also converted to these formats, you just need to enable OpenOffice integration following this steps:
Document Conversion with OpenOffice
Then, go to Web Content Display configuration and enable the "Convert To" checkboxes.
That's it, hope these features can be useful for you!