I have a problem that cropped up recently, on a site I built a while ago. The site has a shopping cart system, that relies on a session variable to store the ''cart'' object. The code works fine locally in development mode. But on the server it loses the session in the checkout process, after the first form page is sent - the next page loads and the cart has disappeared. Unfortunately, it was a couple of the clients customers that raised this issue :-/ Now I have been trawling the net looking for an answer and I have a feeling it may be due to new ''lazy loading'' of sessions. I have put in before_filters to make sure that the session is called at every request apart from the user account controller. It still loses it at this one page... Running Rails 2.3.3 on both development and production (server). Any ideas much appreciated! Thx -- Posted via http://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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On Tue, Dec 22, 2009 at 4:26 PM, Adam Wilson <lists-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> The code works fine locally in development mode.How does it work locally in production mode? :-)> But on the server it loses the session in the checkout process/> It still loses it at this one page...I''d use Firebug to watch the request/response as you cross that point, checking the cookies particularly. FWIW, -- Hassan Schroeder ------------------------ hassan.schroeder-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org twitter: @hassan -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
On Dec 22, 7:26 pm, Adam Wilson <li...-fsXkhYbjdPsEEoCn2XhGlw@public.gmane.org> wrote:> I have a problem that cropped up recently, on a site I built a while > ago. The site has a shopping cart system, that relies on a session > variable to store the ''cart'' object. > > The code works fine locally in development mode. But on the server it > loses the session in the checkout process, after the first form page is > sent - the next page loads and the cart has disappeared. Unfortunately, > it was a couple of the clients customers that raised this issue :-/ > > Now I have been trawling the net looking for an answer and I have a > feeling it may be due to new ''lazy loading'' of sessions. > > I have put in before_filters to make sure that the session is called at > every request apart from the user account controller. It still loses it > at this one page... > > Running Rails 2.3.3 on both development and production (server). > > Any ideas much appreciated! Thx > -- > Posted viahttp://www.ruby-forum.com/.Do you force the SSL on the checkout process? What is the common name on the cert? Does it exactly match the FQDN you''re accessing the site from before you start checkout? -- 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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.
Adam Wilson wrote:> I have a problem that cropped up recently, on a site I built a while > ago. The site has a shopping cart system, that relies on a session > variable to store the ''cart'' object. > > The code works fine locally in development mode. But on the server it > loses the session in the checkout process, after the first form page is > sent - the next page loads and the cart has disappeared. Unfortunately, > it was a couple of the clients customers that raised this issue :-/ > > Now I have been trawling the net looking for an answer and I have a > feeling it may be due to new ''lazy loading'' of sessions. > > I have put in before_filters to make sure that the session is called at > every request apart from the user account controller. It still loses it > at this one page... > > Running Rails 2.3.3 on both development and production (server). > > Any ideas much appreciated! ThxOk... sorry - it was a problem with the https apache config pointing to the old port number... -- Posted via http://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 rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.