score:18
I did it work as explained at given URL:
function updateGraphic(url, chartName) {
chartName.showLoading();
$.getJSON(url, function(data){
chartName.series[0].setData(data);
chartName.hideLoading();
});
}
score:0
You can define globally for each page using this plugin JQuery Block UI
and usage is
jQuery(document).ready(function ($) {
$.ajaxSetup({ cache: false });
$(document).ajaxStart(function () {
$('body').block({
message: '<h3><img alt="" class="GifIcon" src="Images/319.gif" />Please wait Data is Loading From Server ...... </h3>'
});
});
$(document).ajaxStop(function () {
$('body').unblock();
});
});
score:0
Modify the css classes of highcharts:
.highcharts-loading {
display: flex;
align-items: flex-start;
justify-content: center;
}
.highcharts-loading-inner {
border: 8px solid #f3f3f3;
border-top: 8px solid #252222;
border-radius: 50%;
width: 60px;
height: 60px;
animation: spin 2s linear infinite;
}
@keyframes spin {
0% { transform: rotate(0deg); }
100% { transform: rotate(360deg); }
}
Based on: How TO - CSS Loader
score:5
This is a simple piece i always use to show the loading.
let's say this is our container
<div id='container'>
<img id="spinner" src="/assets/chart_loader.gif"/>
</div>
And this is the piece of ajax that takes care to show when the getJson starts for the chart and hide when it stops.
$(document).ajaxStart ->
$("#spinner").show()
$(document).ajaxComplete ->
$("#spinner").hide()
score:15
"Loading.." word seems too amateur. Use that trick instead
var chart = new Highcharts.Chart(options);
chart.showLoading('<img src="/images/spinner.gif">');
$.getJSON(url, function(data){
//load data to chart
chart.hideLoading();
});
Source: stackoverflow.com
Related Query
- Highcharts How to Show Loading Animation At Set Data
- highcharts how to have loading animation after data update?
- How to show No Data Available Message in highcharts
- how to set dynamic data in highcharts
- How To Show All Data Labels For Datetime Axis In Highcharts
- How to show plotlines on highstock when its set much higher than the data series?
- Highcharts - how to set textShadow for data labels
- How can I show all Timeline Highcharts data without any overlapping?
- HighCharts how to add live series data set to existing chart
- Highcharts legend how to show multiple charts data category?
- How to show values in Highcharts tooltip other than x and y when data points are too high?
- Highcharts how to make a set number of colors for pie chart data and drilldown data
- How can i load external json data in highcharts to show the bar chart
- How to change line color when loading static csv data into Highcharts Highstock graph?
- Highcharts show loading icon when fetching data in javascript
- How to show horizontal line instead of a dot for a single value data in highcharts
- React: How to show correct date and plot data as Months in Highcharts
- How to have multiple highcharts with different series data in vuejs without repeating code
- Highcharts Highstock How to Plot OHLC and Line Charts from One Set of Embedded CSV Data Using Series Map Tools?
- How to set point in highcharts when x axis and y axis has data as text values?
- how to show mutipal dynamic highcharts based on json data
- How to set Highcharts data series in x-axis using crosshairs?
- how do i link my sqlite(PDO) databse data to highcharts code
- Bars does not show up when loading JSON encoded data from PHP in Highcharts
- How to show data point in Box Plot highcharts
- How to show real time HighCharts Line Graph data which is receiving by an API?
- How to show equally spaced axis for datetime for billing cycle related data on highcharts
- How to make Highcharts default pie not show when Angular page loading
- Show message "Loading..." in Highcharts on loading data from array
- How to set columnrange width to expand the length of the x-axis in multiple data series in Highcharts
More Query from same tag
- Hide categories with value below than specific value Highcharts
- Combination of charts in highcharts overlapping each other
- How can I change the text of the back button on this dropdown pie chart?
- Highcharts Point Value Disappearing
- Highcharts - x axis incorrect date labels appearing
- Inner size of pie chart (HighChart) getting change with the values provided in the series
- Highcharts 3 cannot render more than 1000 points in one series
- Can someone help me to provide space between the time stamps on x-axis
- Does Angular 4 supports highcharts-angular (Highcharts wrapper for Angular)?
- Displaying additional text for Highcharts Bubble chart
- How to change the background color of measure tool in stock chart in highstock?
- Server-Side HighStock charts generation with NodeJS
- Highlight a region in scatter plot using Highcharts
- xAxis tickInterval throwing error in fullscreen
- Hiding a highchart series is very slow
- Highcharts: Difference between onMouseOver vs onContainerPointerMove?
- Highchart chinese colon display incorrect when exporting
- Chart area exceeding series length
- Highchart redraw is throwing error Uncaught TypeError: Cannot read property 'length' of undefined(…)
- How to remove space below the semi-circle in highcharts?
- Setting tick interval dynamically in highstock chart
- HighMap displaying issue with customized json file
- show tooltip in highcharts
- creating a bar chart using Highcharts with React - getting an error that rendering div isn't found
- How to change the legend data highcharts
- Using HIghcharts on Codeigniter to get data name and total
- How to remove Highcharts grid end lines on x and y axis?
- How to put two charts on the same page with different modules?
- Finding width of secondary yaxis
- How to ignore hidden series when clicking on a legend using highcharts?