Until this point, we've mostly been getting data from some source. We never modify or change data at the source. This recipe will briefly go through the details of how we might send data to some server that affects our chart.
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. For our example, assume that the JSON we retrieve looks like the following code:
{'y': 0}
To get started, perform the following steps:
Create a textbox and a button on our page as follows:
<div id='container'></div><br/> <input type='text' id='new_value' /> <input type='submit' id='replace_value' value="Replace value"/>
Create a handler for the instance when the button is pressed, as shown in the following code:
$('#replace_value'').on('click', function(event) { var newValue = $('#new_value').val(); ...