Jump to:

796 Posts in 409 Topics by 304 members


SilverStripe Forums » Widgets » Smile Timeline for Silverstripe!?

Discuss SilverStripe Widgets.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 985 Views
  • Noki
    Community Member
    6 Posts

    Smile Timeline for Silverstripe!? Link to this post

    i try to integrate the Smile Timeline to Silverstripe. (http://www.simile-widgets.org/timeline/)
    Usually the data for the Timeline comes from a XML or JSON File, but i would like to get them from the Database.

    I created a TimelineEventPage where the user can add some events. But how can I read and use the Data for the Timeline in the java script?

    The following code is loading the "timeline.xml" file with the event-data. how should I change the code to get the data from silverstripe?

    <script ....

    . . .
    tl = Timeline.create(document.getElementById("my-timeline"), bandInfos);
    tl.loadJSON("timeline.xml?"+ (new Date().getTime()), function(json, url) {
    eventSource.loadJSON(json, url);

    The XML-file:

    wiki-section="Simile JFK Timeline">
    start="Sat May 20 1961 00:00:00 GMT-0600"
    title="'Bay of Pigs' Invasion">
    start="Wed May 01 1963 00:00:00 GMT-0600"
    end="Sat Jun 01 1963 00:00:00 GMT-0600"
    title="Oswald moves to New Orleans">
    Oswald moves to New Orleans, and finds employment at the William <!-- The event's description -->
    B. Riley Coffee Company. &lt;i&gt;ref. Treachery in Dallas, p 320&lt;/i&gt;

    Can anybody help?

    Thanks Ben

  • swaiba
    Forum Moderator
    1796 Posts

    Re: Smile Timeline for Silverstripe!? Link to this post

    Probably not of interest to you now Noki, but for future reference there is an SS module for timeline...


Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.