2023-09-30 22:45:55 +00:00
|
|
|
<!doctype html>
|
|
|
|
<html lang="en-GB">
|
|
|
|
<head>
|
|
|
|
<meta charset="UTF-8" />
|
|
|
|
<meta http-equiv="content-type" content="text/html" charset="UTF-8" />
|
|
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
|
|
<meta name="description" content="" />
|
|
|
|
<meta name="keyword" content="" />
|
|
|
|
|
|
|
|
<!-- <script src="http://cdn.hiimray.co.uk/8206c600-707c-469e-8d49-a76ae35782af/bootstrap/5.3.0/dist/js/bootstrap.bundle.min.js"></script> -->
|
|
|
|
<!-- <link href="http://cdn.hiimray.co.uk/8206c600-707c-469e-8d49-a76ae35782af/bootstrap/5.3.0/dist/css/bootstrap.min.css" rel="stylesheet" /> -->
|
|
|
|
|
|
|
|
<link href="bbtimeline.css" rel="stylesheet" />
|
|
|
|
<script src="bbtimeline.js"></script>
|
|
|
|
<!-- <link href="bbtimeline.min.css" rel="stylesheet" /> -->
|
|
|
|
<!-- <script src="bbtimeline.min.js"></script> -->
|
|
|
|
|
|
|
|
<title></title>
|
|
|
|
</head>
|
|
|
|
<body>
|
|
|
|
|
|
|
|
<canvas id="myCanvas"></canvas>
|
|
|
|
|
|
|
|
<p>
|
|
|
|
<button onclick="Clear()">Clear</button>
|
2023-10-01 02:37:24 +00:00
|
|
|
<button onclick="LoadToday()">Load Today</button>
|
|
|
|
<button onclick="LoadNext()">Load Next Month</button>
|
2023-09-30 22:45:55 +00:00
|
|
|
|
|
|
|
</p>
|
|
|
|
|
|
|
|
<style>
|
|
|
|
|
|
|
|
body {
|
|
|
|
padding: 20px;
|
|
|
|
}
|
|
|
|
|
|
|
|
canvas {
|
|
|
|
border-style: solid;
|
|
|
|
border-width: 1px;
|
|
|
|
border-color: #000000;
|
|
|
|
width: 100%;
|
2023-10-01 02:37:24 +00:00
|
|
|
height: 300px;
|
2023-09-30 22:45:55 +00:00
|
|
|
padding: 0;
|
|
|
|
margin: 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
</style>
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
|
|
|
var timeline1 = new BBTimeline("myCanvas");
|
|
|
|
|
|
|
|
timeline1.Load();
|
2023-10-01 02:37:24 +00:00
|
|
|
timeline1.AddEvent("2023-10-05", "title", "description", "link");
|
|
|
|
timeline1.AddEvent("2023-10-06", "title", "description", "link");
|
|
|
|
timeline1.AddEvent("2023-10-16", "title", "description", "link");
|
2023-09-30 22:45:55 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
function Clear()
|
|
|
|
{
|
2023-10-01 02:37:24 +00:00
|
|
|
timeline1.Clear(true);
|
2023-09-30 22:45:55 +00:00
|
|
|
}
|
|
|
|
|
2023-10-01 02:37:24 +00:00
|
|
|
function LoadToday()
|
|
|
|
{
|
|
|
|
timeline1.Load(new Date());
|
|
|
|
}
|
|
|
|
|
|
|
|
function LoadNext()
|
|
|
|
{
|
|
|
|
let date = timeline1.StartDate;
|
|
|
|
date.setMonth(date.getMonth() + 1);
|
|
|
|
|
|
|
|
timeline1.Load(date);
|
|
|
|
}
|
2023-09-30 22:45:55 +00:00
|
|
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
|
|
</body>
|
|
|
|
</html>
|