Re: [xwiki-users] Getting rendered content of a pagewith aspecifictemplate

2007-12-03 Thread BOUSQUET Jeremie
Hi Ricardo,

 

In first instance I copied the sample (the timeline) in a WIKI page, but of 
course as in the sample are defined html, head and body tags, it could 
not work. In a wiki page we already are inside the body tag, and the browser 
does not like redefining such tags very much.

 

I then tried the trick from the TIMELINE-24 issue also, but it failed to work. 
I don't know if I left this patch on the page, because my wiki is currently 
broken ... :/ It removed the URL prefiks issue, but nothing was displayed.

 

So the trick was to have a page WikiDev.TimeLine, with the sample, another page 
WikiDev.TimeLineFeed with the sample script to generate the XML (it works well, 
I only added new things inside it). Basically the timeline feed page generates 
XML with a root data tag, and a number of event tags inside, with a date 
(start) and a description. So it's very easy to generate using any events 
as entries. In the WikiDev.TimeLine page you have to put URL of 
WikiDev.TimeLineFeed as first parameter of the tl.loadxml() method.

 

Then, in the page where I want to show the timeline, I added a iframe, with 
src equals URL of WikiDev.TimeLine. Also had to give it a height and width 
for proper display. Inside the iframe it's like in another page, so there is 
no problem of head or body tags anymore. The WikiDev.TimeLine page does not 
show up (you get the URL prefiks error), but the iframe in the other page 
should display correctly.

 

Hope this helps ...

 

Regards,

 

 

Jeremie

 

 



From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Your XEN ICT 
Team - Ricardo Rodriguez
Sent: dimanche 2 décembre 2007 13:13
To: XWiki Users
Subject: Re: [xwiki-users] Getting rendered content of a pagewith 
aspecifictemplate

 

BOUSQUET Jeremie wrote: 

Hi all,

 

I, of course, completely agree, as said I merely put 2 things together ;-)

The timeline is a great feature, I'm currently working on adding all this 
information in the same timeline (using groovy), and use it in the homepage:

of course, blog news

page updates

FAQ entries

comments on pages

 

The result is not yet perfect, but it's working quite nicely, using different 
bullets colors depending on type of item. I still have a problem in Jeremi's 
part (XML generation), because it seems that most recent entry in RSS is not 
taken into account in generated XML, and I really don't understand why (it's a 
for $entry in $entries with xwiki.feed.getFeeds(url), it should retrieve 
everything !?)

 

Also, when your timeline is rich it's quite unreadable, because newer things 
go too far in the bottom and don't display at all. I'm trying to make the 
timeline automatically magnify itselfs for current period of time (+- n 
hours), so items will be able to show up side-by-side, but I'm still failing to 
do it. 

 

The timeplot also seems very cool ;-) Only problem (for both timeline  
timeplot) is that if it's rich it can take long to show up ... But it's a very 
nice and synthetic display.

 

Regards,

Jeremie 


Hi,

I've been trying to understand why the iframe trick is needed. Just to help 
to follow this issue... http://simile.mit.edu/issues/browse/TIMELINE-24

But I am still far from being able to contribute with an useful page about the 
use Timeline within XWiki. I am not even able to feed a sample Timeline with 
any thing different than the Jeremi's example at 
http://www.jeremi.info/index.php/feed/rss2!

Please, Jeremi, could you provide some example about how to feed the timeline 
simply with xwiki blog news?

Thank you so much,

Ricardo



-- 
Ricardo Rodríguez
Your XEN ICT Team
___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users


Re: [xwiki-users] Getting rendered content of a pagewith aspecifictemplate

2007-12-03 Thread Your XEN ICT Team - Ricardo Rodriguez

BOUSQUET Jeremie wrote:


Hi Ricardo,



Hi!


 

In first instance I copied the sample (the timeline) in a WIKI page, 
but of course as in the sample are defined html, head and body 
tags, it could not work. In a wiki page we already are inside the 
body tag, and the browser does not like redefining such tags very much.




I have not a clear idea about how to have this kind of head and body 
nested tags affect the rendering of the page.


Take a look at this...

http://xepecnet.environmentalchange.net/xwiki/bin/view/ICT/GoogleMaps

Here the code...

http://xepecnet.environmentalchange.net/xwiki/bin/view/ICT/GoogleMaps?viewer=codeshowlinenumbers=0language=en

head and body are also defined in the Google Maps snippet, but the 
page is correctly rendered. No errors at all.


 

I then tried the trick from the TIMELINE-24 issue also, but it failed 
to work. I don't know if I left this patch on the page, because my 
wiki is currently broken ... :/ It removed the URL prefiks issue, but 
nothing was displayed.




I didn't succeed by specifying a value for Timeline_urlPrefix. And I 
don't know how to apply the patch proposed by Sami Radi last October. Of 
course I can put timeline-api.js in one of our servers and modify it, 
but I don't know how to call all the dependencies.


 So the trick was to have a page WikiDev.TimeLine, with the sample, 
another page WikiDev.TimeLineFeed with the sample script to generate 
the XML (it works well, I only added new things inside it). Basically 
the timeline feed page generates XML with a root data tag, and a 
number of event tags inside, with a date (start) and a 
description. So it's very easy to generate using any events as 
entries. In the WikiDev.TimeLine page you have to put URL of 
WikiDev.TimeLineFeed as first parameter of the tl.loadxml() method.




This is another point I fail at. I am not a programmer, so I have to 
learn how to produce this XML output from XWiki items.


Let's write down here a couple of simple examples showing the structure 
you describe...


http://simile.mit.edu/timeline/docs/example1.xml

http://simile.mit.edu/timeline/docs/example2.xml

And the HOW-TO from Simile...

http://simile.mit.edu/timeline/docs/create-timelines.html


 

Then, in the page where I want to show the timeline, I added a 
iframe, with src equals URL of WikiDev.TimeLine. Also had to give 
it a height and width for proper display. Inside the iframe it's 
like in another page, so there is no problem of head or body tags 
anymore. The WikiDev.TimeLine page does not show up (you get the URL 
prefiks error), but the iframe in the other page should display 
correctly.




The iframe way works perfectly. I am only still curious to understand 
why Google Maps work without it.


 


Hope this helps ...



Yes, it does! Thanks for your message, Jeremi. I keep working to produce 
a clear page about how to use Simile TimeLine in XWiki, although I think 
you are the one for this task! :-)


 


Regards,

 



Cheers,

--
Ricardo Rodríguez
Your XEN ICT Team

___
users mailing list
users@xwiki.org
http://lists.xwiki.org/mailman/listinfo/users