Let's get some AJAX in NWiki: History Timelines

Let's get some AJAX in NWiki: History Timelines

by Ludo (Marc Alier) -
Number of replies: 3
Esther Galimany, a dfwikiteam developer asked me tree months ago to release her of workload (related to templates that she just finished) to spend some time playing with a AJAX library that creates very good looking timeline schemes ( ust like the ones that google released a few weeks ago). I told her to implement a alternative view of the wiki history. She (with the help of Modesto Caballero and of course Pigui and even Pablo Casado) has done a superb job and is going out in the (long waited) release (that Pigui is holding wink ).
I copy and paste the nwiki timelines user's guide in our wiki
Hope you like it. estupendo
Ludo


Timeline is a DHTML-based AJAX widget for visualizing time-based events.

In wiki module of DFWikiteam you can see the modifications of wiki pages with a timeline.

Another way of visualizing the hist of the wiki and the tabs Differences and Highligth diferences. All in a completely visual way



How you can accede to the timeline of a wiki?

The timeline is accessible from the following blocks:

  • Wiki - Administration Tools
  • Wiki - Page List
  • Wiki - Index
  • Wiki - Index from current



You have to follow the link, that is like the image of later, that you were finding in every blocK.

link_timeline



How is a timeline wiki?

This one is the appearance of a timeline wiki

timeline_vista_general_centrada

Wiki Timeline



Information showed in the timeline



info_timeline

For every event in the timeline there are a dialog. In this dialog you can:

  • read the complete title of the page, because in the timeline only show a little title.
  • number of version page (the event modification)
  • user name (link to user profile)
  • links versions
    • current page
    • version next that version of event (if exist)
    • version of event
    • version old that version of event (if exist)
  • Differences
  • Highlight diferences
  • Date



The dialog appear if you clicked on a picture or name of event.

How to moving in the timeline

You can move for the timeline to press the mouse, and to displease him keeping it clicked. When you stop to press the mouse the timeline run in the time.

If you move the timeline from the band of events, you move the timeline in the time more slowly. If you move for the band of up of events, with temporary scale are bigger than the scale of band of events, with the same tour of the mouse, you move the timeline more in the time.

In the band 1 and 2 (bands without events) you can see a little blue marks, this marks represent the events, if you don't see events, because in the days or weeks that you see, don't exist modifications of pages, you can see if in the future or past exist events. Because at right or left that center of timeline you can see blue marks.

That are the filters?



With the filters you can select the name of a user and / or the name of a page. If you clicked in the button "Filters" in the timeline only appear the events that contains the values there are in the filters.

filtre_users_and_pages

Clicked "Clear All" button to go back. You can see all events other time.

If you write some word inside one of the filters of colors, automatic your sides all the events that contain this word highlighted with the color of the corresponding filter.

filter_colors

In this example we can see that the user has used the red filter, introducing the word "v.12".

In the first and second band we see the red mark event, in the center of the timeline.

In the band of events, we see about the image colored red (indicated with the green arrow).


The event's name of page is "1p", but it are colored in the timeline because in the content of the dialogue appear the word to filter color.

The filters search in all information of event (page name, user name, version).

Wiki Timeline Settings



This one is the appearance of a timeline settings wiki

settings





Selects the scales of the 3 temporary bands



It allows to modify the temporary scales of 3 bands of the timeline.

The temporary scale depend of the lasted one of the curs or of the density of events that contains the wiki. Every event is a modification of a page wiki of a user, so much to allow to visualize with comfort all the events in timeline is necessary to fit well the temporary scale.

You can define the temporary scales of three bands, the first band has to have the biggest units of time and the third the smallest, the application allows to do all the possible combinations of units of time, but if you choose very big units of time for the third band, for example years, difficultly we will be able visualize and move in the time with comfort across the timeline.

The first and second band are very useful to be able to move in the time with comfort and rapidly, if you do a click of mouse, and you keep it touched and move up to the center of the timeline, this advances all the events of all the bands.

In the first and second band there appear a few small events, that represent the position of the real event represented in the third band, it allows to have a more general vision of the distribution of the events. this bands permit you to see events, that in the small scales there are situated out of the scoope.

Possible values of the temporary scales:

  • the first temporary scale: weeks, months, years, decades
  • the second temporary scale: days, weeks, months, years
  • third temporary scale: hours, days, weeks, months



Size of the band of events (third band)



Allow to modify the size of the events band (third band), is important that you modify the size, because your permit to show all the events of timeline.

The size will depend on the number of events that they have to locate in the same moment of time, that is to say, if the same hour and day exist many modifications in a page wiki. In this case are necessary that the width of timeline is greatest to show all the events.

What you really define is the number of pixels that the timeline occupy of width, and the total size, 80% is dedicated to the width of the third band.

If the predefined size is not sufficient to you, you can introduce the exact number of pixels that you want that it occupies.

Taking like reference the predefined sizes:

  • small: it is equivalent a 325 px
  • medium: it is equivalent a 430 px
  • great: it is equivalent ao 550 px

Average of ratings: -
In reply to Ludo (Marc Alier)

Re: Let's get some AJAX in NWiki: History Timelines

by Stuart Anderson -
As ever Marc, you and your team never cease to amaze me. I'm keen to play around with this feature. I see it as a very efficient way of seeing which students are doing lots of work, and which students are not contributing. Can the filter system be made to search for words within wiki pages as well, thereby combining page searching into a visual time line? Or would that require too much processing?

I have have one non-wiki related question. I was thinking about trying to play around with moodle code and AJAX myself. I'll need to learn a few things first though. I was thinking it might be nice to see if it is possible to re-write the Glossary text filter so that if the user has AJAX enabled, when clicking on a glossary link they would get an in-line AJAX popup of the entry rather than the popup window. Soooo my question is, what is the AJAX library that Esther used to generate her popups in the wiki timeline implementation? Where can I find it?

Looking forward to the release (Pigui!).

--Stuart.
In reply to Stuart Anderson

Re: Let's get some AJAX in NWiki: History Timelines

by Ludo (Marc Alier) -
Actually the processing for the timelines is done in batch scheduled with the cron.php and storing the data in a static xml file. But it could be hacked to feed from a php file that does the query. But I don't see quite the point in using timelines this way you say with search... maybe is the strong meal I just had wink
Esther used a open source (GPL licensed) timelines engine and adapted it... I'll ask for the URL, but anyway is in the code.
Cheers
Ludo
In reply to Ludo (Marc Alier)

Re: Let's get some AJAX in NWiki: History Timelines

by Stuart Anderson -
> But I don't see quite the point in using timelines this way you say with search... maybe is the strong meal I just had

Agreed. Now I sitting down and thinking about it more I can't really think of an appropriate use case scenario. Best ignore me!

Looking forward to seeing the next release and all your very hard work! Hope the guys and Moodle HQ are blown away.

--Stuart.