AnsweredAssumed Answered

Javascript Spinner with ArcGIS Javascript API

Question asked by DamienRobinson on Jan 15, 2015
Latest reply on Jan 16, 2015 by DamienRobinson



I'm working on a custom javascript based viewer. This viewer will allow a user to perform a query, then it zooms to the relevant extent. This aspect is working great. However i'd like to add a jquery spinner when the query is performed and stop it once the extent has been zoomed to.

For whatever reason, I can't get this spinner to work within the script tags of the arcgis javascript viewer.


I have tried various methods using javascript and other libraries. The basic methodology i'm pursuing is to create two functions, one to stop the spinner, the other to hide the spinner. I downloaded the javascript and css files from the following github: jQuery Spin . I have referenced these in the head of the html page. I have placed the following functions in the map viewer script tags.

function stopSpinner(){






function startSpinner(){








The startSpinner() function will be called on the same button click as the query operation, the stopSpinner() would be called immediately after a getExtent call.


Are there any issues with using jquery and the arcgis javascript api ?


Any advice would be greatly appreciated.