Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
I'm not sure I understand your question completely, but I don't believe this is possible with JavaScript. Are you saying you want your site to have anonymous access, but you still want to be able to prompt them for a username and password? If so, you could restrict access to a subfolder of your site and load a page from this folder into a hidden Iframe to get the prompt, but I don't know what good that would do you. Why do you need to prompt the user for a password on a site that isn't password protected? Can you explain a little further?...regardless security settings