We have made static charts so far. Often, we'll want to update charts periodically to represent changes in the data over time. The best way to do that is using AJAX.
To set up a basic page and install jQuery and Highcharts, refer to the Getting ready section of the Creating your first chart recipe in Chapter 1, Getting Started with Highcharts.
If you already have a server set up or will be setting up your own, many of the following steps can be omitted:
Download Python 2.7 from http://www.python.org/download and install it.
Download pip from http://www.pip-installer.org/en/latest/installing.html and install it.
Run the following command to install Bottle:
pip install bottle==0.11.6
Create a
bottle_server.py
file and include the following code in it:#!/usr/bin/env python2.7 from bottle import run, route, static_file, template, request, response import json import random r = lambda: random.randint(0,255) def jsonp(request, data): if (request.query.callback...