|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
AT&T devCentral & BlackBerry(r) Webcast Series: BlackBerry and GPS -Build Location Awareness into your BlackBerry Applications, July 10th-1:00PM EST. Register Today!
|
|
#1
|
|||
|
|||
|
How to close an existing Window with loggoff facility
Hi I am trying to close my existing window and before closing it will will show a new mini window where It will be written, press ok if you want to log off. else cancel. And I want to make sure that it really logged of from the server no matter how many other same window is open. By the way I am using unix login system in my web page.
Could you please help me to get this interface. Thank you. |
|
#2
|
||||
|
||||
|
RE: How to close an existing Window with loggoff facility
I'd prefer an expiring login, but you can do it this way if you want to and it's possible.
|
|
#3
|
|||
|
|||
|
RE: How to close an existing Window with loggoff facility
you can use javascript to close the window but typically the client will pop up a confirm dialog saying something like "The site you are viewing is trying to close the browser window, Do you want to close the browser window?" instead of just doing it. And it's tricky if you have other windows open, and I do not recommend that you try to close them all. That could get really annoying. Are you using basic HTTP authentication?
P |
|
#4
|
|||
|
|||
|
RE: How to close an existing Window with loggoff facility
I tried the following code:
<?php header("WWW-Authenticate: Basic realm="My Realm""); header('status: 401 Unauthorized'); print "Logout Successfull"; ?> Now I am getting a the same window for filling up the user id and password that I got first to log in to my web site as I used .htaccess file in side the MainPage directory. And if I press cancel it's giving me: Authorization Required This server could not verify that you are authorized to access the document requested. Either you supplied the wrong credentials (e.g., bad password), or your browser doesn't understand how to supply the credentials required. If I press ok without inputting any thing it gives me: "Logout Successfull" Even I tried to fillup the user ID and password and press ok it gives me "Logout Successfull". I assume it's asking me the same user ID and Password that I used for the first login to for .htaccess file. But I don't want none of the above situations. Let me tell you my goal. I think that might help you to understand what I really want to do. I want to use some php code that will log me out from this web site and no matter how many pages are open from the same web sire (Those will be inactive). I mean you have to login again to get atarted again. Just think about hotmail. If it has open several pages from same user account. If you logout one of the page the others are required t olog in again on order to do something. Hope you understand. Plese let me know your advice. |
|
#5
|
|||
|
|||
|
RE: How to close an existing Window with loggoff facility
You are using basic HTTP authentication.
Hotmail does not use basic HTTP authentication. If you want to use basic HTTP authentication, you should read a tutorial on it. You can find one here: http://www.perl-studio.com/php/ and here: http://www.zend.com/manual/features.http-auth.php |
![]() |
| Viewing: Codewalkers Forums > Other Technologies > Client Side Things > How to close an existing Window with loggoff facility |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|
|
|