Forum Discussion
cike,
did you find the way to do it inside javascript?
I need pretty much the same, and was not able to find the answer...
I have a custom component that needs to be plugged only using javascipt to another component after some script on a fly...
something like:
<#if !user.registered> <@liaAddScript> ;(function($){ $('.someClass').append(<@component id="custom-component>); console.log('Im not registered!'); })(LITHIUM.jQuery); </@liaAddScript> <#else> <@liaAddScript> ;(function($){ console.log('im in!!'); })(LITHIUM.jQuery); </@liaAddScript> </#if>
reading your comment, I probably can't do it, not sure if's the correct way to do.
However, the only way I need it's that way, using javascript...
Any ideas?
Hi irach15,
unfortunately, as nathan described in his former posts it is not possible to append a piece of content which is rendered by the @component notation.
For our case we find a solution which adds the pagination component via Freemarker. To handle the pagination we wrote some JavaScript which works with our component and community structure.
Regards,
Christian
Related Content
- 4 years agoInactive User
- 6 months ago