Q:

Refresh (or change) background image dynamically

I'd appreciate any help with this.
What I need to do is refresh/change the background image of a live chart, every time that I add some data to it. The live data part works fine.
I've tried the "chart.plotBGImage.attr({href: 'xxx'});" approach but I get an error: "Cannot read property 'plotBGImage' of undefined". 
Any ideas on what's wrong or for a diffrent approach?
Here's my code so far:
<script type="text/javascript">
    var chart1; 

    function requestData() {
        $.ajax({
            url: 'get_data/getECGdata.php',
            success: function(point) {

                var series1 = chart1.series[0],
                shift = series1.data.length > 20; 

                // add the point
                chart1.series[0].addPoint(eval(point), true, shift);    

                //The line below is the one giving the error
                //this.chart1.plotBGImage.attr({href: "http://www.highcharts.com/images/stories/logohighcharts.png"});              

                // call it again after one/two/etc seconds
                setTimeout(requestData, 1000);  
                },
            cache: false
        });
    }

    $(document).ready(function() {

        chart1 = new Highcharts.Chart({
            chart: {
                renderTo: 'container',
                zoomType: 'x',
                backgroundColor:'rgba(255, 255, 255, 0.4)',
                defaultSeriesType: 'line',
                marginTop: 60,
                events: {load: requestData}
            },
            title: {text: 'Live ECG data'},
            xAxis: {type: 'datetime', tickPixelInterval: 150, maxZoom: 20 * 1000},
            yAxis: {minPadding: 0.2, maxPadding: 0.2, title: {text:'ECG reading', margin: 20 } },
            tooltip: {xDateFormat: '%H:%M:%S', shared: true},
            credits: {enabled: false},
            series: [
                    {name: 'ECG', color: 'green', data: [] }

                ]
        });

    });
    </script>

A:

I understand that u are trying to change the background image in the Highchart.
Just giving chart.plotBGImage.attr({href: 'xxx'}); will not help, u will need to reload the entire HighChart.
I did this (without the Live Data part as its working fine for you!!) Fiddle

