0

I’m interested in integrating Highcharts into my Weebly page but am struggling to get it to work. I can get the “Cloud” version to display, but can’t get any of the JS based graphs to load.

I have included this in the Header section of the SEO setting:

<scriptsrc="//ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
<scriptsrc="//code.highcharts.com/highcharts.js"></script>
<scriptsrc="//code.highcharts.com/modules/data.js"></script>?

And this is included in the Embed section on a normal page:

$(function () {
$('#container').highcharts({
    chart: {
        type: 'bar'
    },
    title: {
        text: 'Fruit Consumption'
    },
    xAxis: {
        categories: ['Apples', 'Bananas', 'Oranges']
    },
    yAxis: {
        title: {
            text: 'Fruit eaten'
        }
    },
    series: [{
        name: 'Jane',
        data: [1, 0, 4]
    }, {
        name: 'John',
        data: [5, 7, 3]
    }],
});
});

That's an example from JSFiddle. When I publish the page all I get is the code in a box and no graph. Can anyone point me in the right direction please?

Thanks

Ross
  • 1
  • Do you have any errors in your console? – Grzegorz Blachliński Sep 09 '16 at 08:59
  • I do, they are: The value "1.0;" for key "initial-scale" was truncated to its numeric prefix. Error parsing a meta element's content: ';' is not a valid key-value pair separator. Please use ',' instead. I don't see to have control over these inputs though unless I'm missing something. – Ross Sep 12 '16 at 01:26
  • They're both happening in the line . – Ross Sep 12 '16 at 01:34
  • How's that error connected to Highcharts? It looks like the error is not connected to Highcharts. – Kacper Madej Sep 16 '16 at 11:08

1 Answers1

0

You have to add the entire link to the libraries:

<script src="https://code.jquery.com/jquery-3.1.1.min.js"></script>

<script src="https://code.highcharts.com/highcharts.js"></script>

<script src="https://code.highcharts.com/modules/data.js"></script>

Here a demo with the code you selected: https://junefirst.weebly.com/ the first demo is using Highchart cloud and the second is your demo

mustapha mekhatria
  • 3,495
  • 1
  • 20
  • 26