Sorted out!
>From PHP:
$html .= " tl = Timeline.create(document.getElementById('$divID'),
bandInfos);" . PHP_EOL;
$html .= " eventSource.loadJSON($eventSource,
document.location.href);" . PHP_EOL;
that give me this HTML:
var tl;
function onLoad() {
var eventSrc = new Timeline.DefaultEventSource();
var bandInfos = [
Timeline.createBandInfo({
eventSource: eventSrc,
width: "80%",
intervalUnit: Timeline.DateTime.MONTH,
intervalPixels: 100
}),
Timeline.createBandInfo({
eventSource: eventSrc,
overview: true,
width: "20%",
intervalUnit: Timeline.DateTime.YEAR,
intervalPixels: 200
})
];
bandInfos[1].syncWith = 0;
bandInfos[1].highlight = true;
tl = Timeline.create(document.getElementById("tline"), bandInfos);
eventSrc.loadJSON({"dateTimeFormat":"Gregorian","events":[{"title":"Vessel
Two","start":"Thu, 20 Mar 2014 00:00:00 +1030","durationEvent":true,"end":"Sun,
23 Mar 2014 00:00:00 +1030","color":"#0000FF"},{"title":"Vessel
Two","start":"Wed, 23 Apr 2014 00:00:00
+0930","durationEvent":false,"color":"#0000FF"}]}, document.location.href);
}
--
You received this message because you are subscribed to the Google Groups
"SIMILE Widgets" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/simile-widgets.
For more options, visit https://groups.google.com/d/optout.