Kent,
   I guess I really haven't thought it through, but my original
purpose was to group a visit using the session id as opposed to an ip
which could potentially be the same for two visitors. You mentioned
where I set the session id, but I don't do it, SqlSessionStore does it
for me, but I'm curious has to how that works. Do you know when the
session would be set?

On Oct 22, 10:25 am, Kent Fenwick <[EMAIL PROTECTED]>
wrote:
> It makes sense that the initial visit would not have a session id
> because depending on where you are assigning it, you might be logging
> the variable before setting it.
>
> Also, you don't really need to hang on to the session details when
> logging web visits. Unless you have a special reason to, i wouldn't
> track any of the session details, they can easily be crated and
> compromised by scripts anyway.  Try to keep session data to a minimum.
>
> You might need to show some code if this doesn't help.
>
> Kent
>
> gwgeller wrote:
> > I am logging web visits with a before_filter on the application
> > controller. The issue I'm having is that the initial visit does not
> > return a session id. I'm using the SqlSessionStore and the function
> > MysqlSession.find_session(session.session_id) to retrieve the session
> > id. If it doesn't exist I use a -1. So looking in my visits table the
> > initial visit always has -1 for the session id and the rest of the
> > visits contain a valid session id for that visitor.
>
> > I tried putting the logging of visits in the after filter but that
> > didn't seem to work. Is this something that I can correct or is that
> > just the way it is with sessions?
>
> > Thanks,
> > Gunner
>
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to