On Tue, Nov 22, 2011 at 11:14 AM, jerem <[email protected]> wrote:
Hello,
I'm trying to "execute" a page from another page. The "executed" page has some groovy and velocity, does some queries, and as output attaches a computed file to itself (and outputs some success or error message to page content). "Executing" it means just showing the page, as a result the attachment gets increased version.
Now I want to do the same but calling it from another page. This is what I did :
xwiki.getDocument('Space.MyPageToExecute').getRenderedContent()
What about: {{include document="Space.MyPageToExecute" context="new" /}} See http://extensions.xwiki.org/xwiki/bin/view/Extension/Include+Macro . Hope this helps, Marius
This returns my success message, but nothing gets attached. Is there any chance that this could work ? I checked the rights of my user (set correct user in context before the setAttachment()) but I could not make it work ... Am I forced to write my page as a groovy class to achieve this ?
Thanks, Jeremie
-- View this message in context: http://xwiki.475771.n2.nabble.com/Executing-a-page-from-another-page-tp70198... Sent from the XWiki- Users mailing list archive at Nabble.com. _______________________________________________ users mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/users