Screen lock via only JS

asked 2013-05-28 08:57:53 +0800

icju gravatar image icju

Does is possible to lock screen using ONLY JS (i mean not via Clients.showBusy etc..). I need to lock screen immediately.

delete flag offensive retag edit


Do you want for each ajax request the page show some busy mask?

sjoshi ( 2013-05-28 10:37:18 +0800 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2013-05-28 13:38:11 +0800

psingh gravatar image psingh flag of India
963 8

You can just show / hide a gif, but you can also embed that to ajaxSetup, so it's called on every ajax request.

        // show gif here, eg:
        // hide gif here, eg:

One note is that if you want to do an specific ajax request without having the loading spinner, you can do it like this:

   global: false,
   // stuff

That way the previous $.ajaxSetup we did will not affect the request with global: false.

More details available at: http://api.jquery.com/jQuery.ajaxSetup

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

1 follower



Asked: 2013-05-28 08:57:53 +0800

Seen: 14 times

Last updated: May 28 '13

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More