473,395 Members | 1,343 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

allow a user to signoff

I need to allow a user to sign off from the admin section of my site. I am
using forms based authentication again a DB.
I have read several articles today... none mention how to do this. I guess
I could force an expiration of the cookie, but there must be a cleaner way.

Anyone know one?

Thanks-
Steve
Nov 18 '05 #1
4 1685
> I could force an expiration of the cookie, but there must be a cleaner
way.

That's the way it is done, setting an expire date in the past - whether
using client side JavaScript or server side ASP.NET code execution.

--
Peter O'Reilly
Nov 18 '05 #2
> I could force an expiration of the cookie, but there must be a cleaner
way.

That's the way it is done, setting an expire date in the past - whether
using client side JavaScript or server side ASP.NET code execution.

--
Peter O'Reilly
Nov 18 '05 #3
Steve,

If you are using FormsAuthentication, you can do
FormsAuthentication.SignOut() and this will destroy the ticket associated
with the user. I put this in an event for a button and then
Response.Redirect(BackToMainPageOrWhereEver) after the SignOut() is called.
In my case, I also do a session.destroy before the Response.Redirect as
well.

HTH,

Raymond Lewallen

"sklett" <as**@fkd.com> wrote in message
news:eG**************@TK2MSFTNGP10.phx.gbl...
I need to allow a user to sign off from the admin section of my site. I am using forms based authentication again a DB.
I have read several articles today... none mention how to do this. I guess I could force an expiration of the cookie, but there must be a cleaner way.
Anyone know one?

Thanks-
Steve

Nov 18 '05 #4
Steve,

If you are using FormsAuthentication, you can do
FormsAuthentication.SignOut() and this will destroy the ticket associated
with the user. I put this in an event for a button and then
Response.Redirect(BackToMainPageOrWhereEver) after the SignOut() is called.
In my case, I also do a session.destroy before the Response.Redirect as
well.

HTH,

Raymond Lewallen

"sklett" <as**@fkd.com> wrote in message
news:eG**************@TK2MSFTNGP10.phx.gbl...
I need to allow a user to sign off from the admin section of my site. I am using forms based authentication again a DB.
I have read several articles today... none mention how to do this. I guess I could force an expiration of the cookie, but there must be a cleaner way.
Anyone know one?

Thanks-
Steve

Nov 18 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: Who | last post by:
What is required on the server to publish asp.net and webform apps. on the www? I am assuming IIS, frontpage extensions (not sure about which version). What about database usage. Say I want to use...
2
by: sklett | last post by:
I need to allow a user to sign off from the admin section of my site. I am using forms based authentication again a DB. I have read several articles today... none mention how to do this. I guess...
8
by: Who | last post by:
What is required on the server to publish asp.net and webform apps. on the www? I am assuming IIS, frontpage extensions (not sure about which version). What about database usage. Say I want to use...
2
by: sklett | last post by:
I need to allow a user to sign off from the admin section of my site. I am using forms based authentication again a DB. I have read several articles today... none mention how to do this. I guess...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.