On Oct 24, 11:13 am, cjrh <caleb.hatti...@gmail.com> wrote:
> As a side-issue from another post I made recently, it seems to be the
> case that when javascript $.ajax() method is executed, and it points
> to a controller function, a different session is used in that target
> controller function than the original one.  This could be because the
> session cookie is not being submitted in the ajax call itself.  Has
> anyone else seen this?  Is there a way to get fix it?

Ok, I was wrong about pretty much everything:

1) $.ajax() DOES send all the cookies back

2) The session variable IS the same session variable, and it does
update correctly

3) My problem was a race condition.  The function changing the session
as a result of the $.ajax call was being triggered slightly later than
the page refresh itself (I was calling an ajax function in the onclick
event of an A() tag.)   I solved my issue by doing the ajax session
update synchronously, IOW the link redirect had to wait.

So, nothing to see here, move along :)

Reply via email to