Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

ClearAuthenticationCache to logout

Featured Replies

Has anyone been using this command available with IE 6? After reading the forums yesterday and realizing the ONLY way I could get my users to "log-out" via web (and Web Security Database) was to shut down their browser (oh my!), I searched and searched and found this. It does work.

My question is this: do I NEED to use Web Security Database to be most secure? Designing my own system is not sufficient? I have confidential patient information in my database. I only ask because when I was using my own system, it was very easy to "log-out" the user, thus allowing another user to log-in.

Try this ClearAuthenticationCache....I think you will like it! i am thinking about requiring my users to have the latest version of IE so that I can force logouts after inactivity and such.

<?xml version="1.0" encoding="ISO-8859-1"?>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"

"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">

<head>

<title>Logging out of Basic HTTP Auth</title>

</head>

<body>

<p><a href="#" onclick="

document.execCommand('ClearAuthenticationCache');

alert('You are now logged out!');

">Log Me Out</a>

</p>

</body>

</html>

-Courtney

  • Author

By the way, I am thinking about combining this function with a javascript check upon first entry to the site that the user is using IE 6.0 (or up, eventually). If they are not, I won't let them login and will instead direct them to download the latest evrsion of IE. None of my end-users are the real computer-savvy types that will be too opposed to this (anti-MS and all that) I think. What does anyone think of this approach?

I wish all browsers would do that :-)

Well done! All the best.

Garry

A site must be really significant to my needs to get me to use IE as a client. Any business with the "ya gotta use IE attitude" will not get my business unless they are offering something valuable for free.

Shall we talk economic theory and web serving costs including databases, site /maintenance, labor, hardware and ISP?

I, too, can have an eclectic attitude. Sorry if my dogma ran over you karma. laugh.gif

  • Author

Yes, yes I agree. I don't like any site that forces me to use any particular browser, however, my site will not be "open to the public" for business. I work in clinical research and we will be using our site to allow specified offsite users to have access to view and update patient data and some computers will be shared between users and must have the ability to logout without shutting down the browser.

Does that change your opinion?

Hi, C! I've always wondered about logging out users... maybe I'll try your code. As to IE, I support primarily Mac departments (85%). IE 5.2 is the latest version on the Mac and I believe Microsoft announced that it will completely stop development for IE on the Mac platform except for possible security issues. The Mac community went from primarily Netscape to primarily IE after AOL took over Netscape. Now, Apple's hoping everyone will switch to Apple's new browser, Safari (based on Konquer) but it'll be interesting to see who (if anyone) will win the Mac browser war. IMO, Mozilla is the lead candidate for cross-platform (Mac/Win/Unix).

--ST

  • Author

My boyfriend is way into safari (not to mention macs, in general). And although I usually support the idea that many microsoft products are a sad, sad state of affairs, it seems that in this one aspect, namely, the ability to log out from http authentication (which people all over, not just in the FM community have been searching for forever), they are leading the way. I can only hope other browsers will soon follow and save all of us a bunch of headaches.

As to Mozilla, I have just recently downloaded and been playing around with it but I hear nothing but good things (although it does not support the clear http authentication function, as far as I know).

Also, just an update to all, I have very succesfully integrated the ClearAuthenticationCache bit into my site. I especially like it for development as it allows me to quickly test different user privileges and such without shutting down the browser. smile.gif

Thanks for the dialogue, folks-

C

  • 2 weeks later...

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.