kpmcdonakpmcdon
7 years agoQrew Trainee
Code page with highcharts graph displaying blank
I am dipping my toe into using Highcharts graphs and have hit a wall. I should first say that I am a novice, so don't assume much of anything regarding my skill level!
I created a code page (test.html) with a basic sample bar chart that doesn't pull from QuickBase - the data is in the code. I got something similar working using charts.js but when I tried Highcharts it just displays a blank page. I would be grateful if someone could A) explain what I am doing wrong and/or B) point me to a tutorial on using highcharts in QuickBase.
Thanks!
The code is:
I created a code page (test.html) with a basic sample bar chart that doesn't pull from QuickBase - the data is in the code. I got something similar working using charts.js but when I tried Highcharts it just displays a blank page. I would be grateful if someone could A) explain what I am doing wrong and/or B) point me to a tutorial on using highcharts in QuickBase.
Thanks!
The code is:
<script src="https://code.highcharts.com/highcharts.js"></script>
<script src="https://code.highcharts.com/modules/exporting.js"></script>
<div id="container" style="width:100%; height:400px;"></div>
<script type='text/javascript'>
Highcharts.chart('container', {
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]
}]
});
})
</script>