471,310 Members | 1,058 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

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

User Sessions

I am novice programmer. The website of the company I work allows users to
sign in in an individual basis. This means that the same user can only be
logged to the site more than once simultaneously. The site checks for the
username of new sessions. If it's the same, the code terminates the previous
session.
We have to log all activities in the site. If a user attempts to login more
than once, we have to log the IP address of the previous session, the browser
type of the previous session, and the same info for the new session to a
database. That is where I come in. I am not sure how to save the information
(i.e. IP Address, browser type, etc) from session to session. How do I go
about this? I tried writing a session variable at the Session_Start method,
but it gets overwritten every time a new session starts. I need help on this
as soon as possible.

Thanks,
Hecdtor
Jul 21 '05 #1
2 1192
store it in the application object at session on start, and remove it again
at session on end. If you find it already exists then its a duplicate user.

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"hecsan07" <he******@hotmail.com> wrote in message
news:78**********************************@microsof t.com...
I am novice programmer. The website of the company I work allows users to
sign in in an individual basis. This means that the same user can only be
logged to the site more than once simultaneously. The site checks for the
username of new sessions. If it's the same, the code terminates the previous session.
We have to log all activities in the site. If a user attempts to login more than once, we have to log the IP address of the previous session, the browser type of the previous session, and the same info for the new session to a
database. That is where I come in. I am not sure how to save the information (i.e. IP Address, browser type, etc) from session to session. How do I go
about this? I tried writing a session variable at the Session_Start method, but it gets overwritten every time a new session starts. I need help on this as soon as possible.

Thanks,
Hecdtor

Jul 21 '05 #2
The username of the visitor is not yet available at Session OnStart. I need
to check the username to make sure the request comes from the same user.

Hector

"John Timney (ASP.NET MVP)" wrote:
store it in the application object at session on start, and remove it again
at session on end. If you find it already exists then its a duplicate user.

--
Regards

John Timney
ASP.NET MVP
Microsoft Regional Director

"hecsan07" <he******@hotmail.com> wrote in message
news:78**********************************@microsof t.com...
I am novice programmer. The website of the company I work allows users to
sign in in an individual basis. This means that the same user can only be
logged to the site more than once simultaneously. The site checks for the
username of new sessions. If it's the same, the code terminates the

previous
session.
We have to log all activities in the site. If a user attempts to login

more
than once, we have to log the IP address of the previous session, the

browser
type of the previous session, and the same info for the new session to a
database. That is where I come in. I am not sure how to save the

information
(i.e. IP Address, browser type, etc) from session to session. How do I go
about this? I tried writing a session variable at the Session_Start

method,
but it gets overwritten every time a new session starts. I need help on

this
as soon as possible.

Thanks,
Hecdtor


Jul 21 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by fr? | last post: by
15 posts views Thread by Joshua Beall | last post: by
2 posts views Thread by marslee | last post: by
2 posts views Thread by d.schulz81 | last post: by
4 posts views Thread by Matt Anderson | last post: by
13 posts views Thread by Mickey | last post: by
5 posts views Thread by Andy | last post: by
3 posts views Thread by at_the_gonq | last post: by
reply views Thread by rosydwin | last post: by

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.