Auto add loading image when call ajax.

Add below code in your script

Add below code in document ready

Add below code in css

Download icon and copy into your forder. Here