Hi Nils,

You can call on template&paragraph renderers (for example the class 
FreemarkerParagraphRenderer)  the method render(Content content, Paragraph 
paragraph, Writer out).
Additionally there are the methods int the MagnoliaTemplatingUtilities class 
where you just can pass the content you want to render, such as:

public void renderTemplate(Content content) throws RenderException, IOException 
{
        renderTemplate(content, getWriter());
    }
public void renderParagraph(Content paragraphNode) throws RenderException, 
IOException {
        renderParagraph(paragraphNode, getWriter());
    }


To solve you problem would be:
Get the content from pageA (uuidLink control and resolve the UUID for example), 
and pass it to the MagnoliaTemplatingUtilities.renderParagraph(yourContentNode).

You can make this call the the MagnoliaTemplatingUtilities class even in the 
template script.
There it is the object 'mgnl'.
So in scripts it would be ${mgnl.renderParagraph(yourContentNode)}

Cheers
Christian

On Aug 24, 2010, at 3:19 PM, Nils Breunese wrote:

> 
> Matteo Pelucco wrote:
> 
>> quick and dirty question.
>> 
>> Is it possible to rendere a generic content node from Java?
>> I mean..
>> 
>> 1) I call pageA.html
>> 2) Somewhere, a pageA paragraphs needs to produce output rendering a
>> "mirrored" content / paragraph, from pageB, pageC... maybe more than one.
>> 
>> How easy can be to make it working? Obviously, HttpClient call is
>> out-of-scope...
>> 
>> Thanks for any hints!
> 
> Check out the Magnolia API page in the new technical guide for some ideas: 
> http://documentation.magnolia-cms.com/technical-guide/api.html
> 
> Nils.
> 
> De informatie vervat in deze  e-mail en meegezonden bijlagen is uitsluitend 
> bedoeld voor gebruik door de geadresseerde en kan vertrouwelijke informatie 
> bevatten. Openbaarmaking, vermenigvuldiging, verspreiding en/of verstrekking 
> van deze informatie aan derden is voorbehouden aan geadresseerde. De VPRO 
> staat niet in voor de juiste en volledige overbrenging van de inhoud van een 
> verzonden e-mail, noch voor tijdige ontvangst daarvan.
> 
> 
> ----------------------------------------------------------------
> For list details see
> http://www.magnolia-cms.com/home/community/mailing-lists.html
> To unsubscribe, E-mail to: <[email protected]>
> ----------------------------------------------------------------

Best regards,

Christian Ringele
Magnolia International Ltd.

You should join us at Magnolia Conference 2010:
http://www.magnolia-cms.com/conference

Magnolia®  - Simple Open Source Content Management



----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------

Reply via email to