Jump to content

Page busy indicator


elentz

Recommended Posts

I freely admit I am pretty green in alot of this stuff.  I have a php page that runs arp-scan and returns information on MAC addresses for the network.  It takes 10 seconds probably.  I am looking for a visual indication to tell the user that the scan is in progress.  I have no idea what this is even called.  Can someone point me in the direction I need to go to figure this out?

 

Thanks

Link to comment
Share on other sites

You cannot do this with PHP alone, because a long-running PHP script delays the entire response so that the user just sees a blank window.

 

You need JavaScript. More specifically: You need to trigger the PHP script with Ajax. The spinning wheel is called a throbber, and there are plenty of libraries. When you've received the response, you hide the throbber and insert the data from the PHP script into the page (you should make the PHP script output JSON data rather than a plain string).

 

Start with the Ajax part.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.