login window

I would like to know if there is a way to open the login window in modal mode, before accessing the main page of the application.
with database connection and answer management.
Thanks

Hello,
You mean something like this:
Code Snippet ?

Yes,but with control and response from Mysql (I think classic PHP session login in PHP),
there is un snippet or similar code ?

I’ll explain.
is it possible to start the window automatically?
I do not know how to close the window and open the main window, if the DB me
find that the user and password are correct.