Getting XWiki to fetch an outside page for display in a wiki doc?
I know that there are lots of ways to do this, but I'd like to know if anyone has a simple way to display all or part of an arbitrary page in an XWiki document. I don't have a really concrete example at the moment, but things I have wanted to do in the past involve such things as: - putting a display on users' profile pages of their company directory lookup page (which is not in the wiki), either included directly (not so nice) or dissected so that its DOM elements can be extracted and the desired ones reformatted as a part of the page (much better) - posting a table of contents for a reference document, or a table within it, so that I can link directly to the heading or table entry and users need not go to the document and search for the specific information - without having to code each reference by hand, of course I'm pretty sure I know how, using either Javascript or the Java DOM methods supplied with XWiki, to parse and display the information when I get it, but how to go about getting XWiki to fetch the included document seems to escape me. I know that various things such as the feed plugin do this, and I'll probably go to the source to learn how if I don't get an easier answer. But I hope that someone has done this already and has found an easy way to do it. brain[sic]
Hi #set($extcontent = $xwiki.getURLContent("http://....")) Then you can play around with some regular expressions to extract a part of the content you are interested in. You could also do more complex groovy stuff with the groovy xml API.. Ludovic THOMAS, BRIAN M (SBCSI) a écrit :
I know that there are lots of ways to do this, but I'd like to know if anyone has a simple way to display all or part of an arbitrary page in an XWiki document.
I don't have a really concrete example at the moment, but things I have wanted to do in the past involve such things as:
- putting a display on users' profile pages of their company directory lookup page (which is not in the wiki), either included directly (not so nice) or dissected so that its DOM elements can be extracted and the desired ones reformatted as a part of the page (much better) - posting a table of contents for a reference document, or a table within it, so that I can link directly to the heading or table entry and users need not go to the document and search for the specific information - without having to code each reference by hand, of course
I'm pretty sure I know how, using either Javascript or the Java DOM methods supplied with XWiki, to parse and display the information when I get it, but how to go about getting XWiki to fetch the included document seems to escape me. I know that various things such as the feed plugin do this, and I'll probably go to the source to learn how if I don't get an easier answer. But I hope that someone has done this already and has found an easy way to do it.
brain[sic]
------------------------------------------------------------------------
-- You receive this message as a subscriber of the xwiki-users@objectweb.org mailing list. To unsubscribe: mailto:xwiki-users-unsubscribe@objectweb.org For general help: mailto:sympa@objectweb.org?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
-- Ludovic Dubost XPertNet: http://www.xpertnet.fr/ Blog: http://www.ludovic.org/blog/ XWiki: http://www.xwiki.com Skype: ldubost AIM: nvludo Yahoo: ludovic
Ludovic: Thank you again. I'm embarassed that it was right in the main API method... Is it possible to use dom4j on this too? brain[sic]
-----Original Message----- From: Ludovic Dubost [mailto:ludovic@xwiki.com] Sent: Friday, September 08, 2006 4:08 PM To: xwiki-users@objectweb.org Subject: Re: [xwiki-users] Getting XWiki to fetch an outside page for display in a wiki doc?
Hi
#set($extcontent = $xwiki.getURLContent("http://....")) Then you can play around with some regular expressions to extract a part of the content you are interested in.
You could also do more complex groovy stuff with the groovy xml API..
Ludovic
THOMAS, BRIAN M (SBCSI) a écrit :
I know that there are lots of ways to do this, but I'd like to know if anyone has a simple way to display all or part of an arbitrary page in an XWiki document.
I don't have a really concrete example at the moment, but things I have wanted to do in the past involve such things as:
- putting a display on users' profile pages of their company directory lookup page (which is not in the wiki), either included directly (not so nice) or dissected so that its DOM elements can be extracted and the desired ones reformatted as a part of the page (much better) - posting a table of contents for a reference document, or a table within it, so that I can link directly to the heading or table entry and users need not go to the document and search for the specific information - without having to code each reference by hand, of course
I'm pretty sure I know how, using either Javascript or the Java DOM methods supplied with XWiki, to parse and display the information when I get it, but how to go about getting XWiki to fetch the included document seems to escape me. I know that various things such as the feed plugin do this, and I'll probably go to the source to learn how if I don't get an easier answer. But I hope that someone has done this already and has found an easy way to do it.
brain[sic]
----------------------------------------------------------------------
--
-- You receive this message as a subscriber of the xwiki-users@objectweb.org mailing list. To unsubscribe: mailto:xwiki-users-unsubscribe@objectweb.org For general help: mailto:sympa@objectweb.org?subject=help ObjectWeb mailing lists service home page: http://www.objectweb.org/wws
-- Ludovic Dubost XPertNet: http://www.xpertnet.fr/ Blog: http://www.ludovic.org/blog/ XWiki: http://www.xwiki.com Skype: ldubost AIM: nvludo Yahoo: ludovic
participants (2)
-
Ludovic Dubost -
THOMAS, BRIAN M (SBCSI)