diff --git a/examples/ajax.html b/examples/ajax.html new file mode 100644 index 0000000..1ee68f7 --- /dev/null +++ b/examples/ajax.html @@ -0,0 +1,85 @@ + + + + + Flot Examples + + + + + + +

Flot Examples

+ +
+ +

Example of loading data dynamically with AJAX. Percentage change in GDP (source: Eurostat). Click the buttons below.

+ +

The data is fetched over HTTP, in this case directly from text + files. Usually the URL would point to some web server handler + (e.g. a PHP page or Java/.NET/Python/Ruby on Rails handler) that + extracts it from a database and serializes it to JSON.

+ +

+ - + data - + +

+ +

+ - + data - + +

+ +

+ - + data - + +

+ + + + + diff --git a/examples/data-eu-gdp-growth.json b/examples/data-eu-gdp-growth.json new file mode 100644 index 0000000..e722bcc --- /dev/null +++ b/examples/data-eu-gdp-growth.json @@ -0,0 +1,4 @@ +{ + label: 'Europe (EU27)', + data: [[1999, 3.0], [2000, 3.9], [2001, 2.0], [2002, 1.2], [2003, 1.3], [2004, 2.5], [2005, 2.0], [2006, 3.1], [2007, 2.9], [2008, 0.9]] +} diff --git a/examples/data-japan-gdp-growth.json b/examples/data-japan-gdp-growth.json new file mode 100644 index 0000000..09aae77 --- /dev/null +++ b/examples/data-japan-gdp-growth.json @@ -0,0 +1,4 @@ +{ + label: 'Japan', + data: [[1999, -0.1], [2000, 2.9], [2001, 0.2], [2002, 0.3], [2003, 1.4], [2004, 2.7], [2005, 1.9], [2006, 2.0], [2007, 2.3], [2008, -0.7]] +} diff --git a/examples/data-usa-gdp-growth.json b/examples/data-usa-gdp-growth.json new file mode 100644 index 0000000..33fd4d3 --- /dev/null +++ b/examples/data-usa-gdp-growth.json @@ -0,0 +1,4 @@ +{ + label: 'USA', + data: [[1999, 4.4], [2000, 3.7], [2001, 0.8], [2002, 1.6], [2003, 2.5], [2004, 3.6], [2005, 2.9], [2006, 2.8], [2007, 2.0], [2008, 1.1]] +} diff --git a/examples/index.html b/examples/index.html index aa2b3ab..fbada6d 100644 --- a/examples/index.html +++ b/examples/index.html @@ -16,8 +16,8 @@

Being interactive: