Show spinner during login waiting time

Could someone please guide me. I want to show the spinner wheel during the (3 to 4 seconds) time it takes from the summiting a username and password until the activity page appears.

Is there a simple one liner to start the function running?





  • require(['elgg/spinner'], function(spinner) {
  • Many thanks for the help but is this not part a JS script rather than a call from within PHP? 

    Not wanting to get into a discussion about changing the core.... I was hoping to be able to call the spinner at the point which the PHP code accepts the credentials and jumps to activity


    line 78





  • That's already a different HTTP request, and you can't really do anything about/with it, but improve loading times of your activity page. There are things you can do, but it's all very technical and nothing that you would be able to do by copy/pasting server-side code