Jeffrey L. Taylor
2011-Apr-03 04:26 UTC
Different GET response w/ wget and w/ em-http-request
I am trying to fetch http://drdobbs.com/rss/all. With wget or Firefox, works fine. With em-request-http, the server redirects to a login page - 302 status code, HTML response and response LOCATION header set to https://login.techweb.com:443/cas/login?service=http%3A%2F%2Fdrdob +bs.com%2Frss%2Fall&siteId=3600005&successfulLoginRedirect=http%3A%2F%2Fdrdobbs. +com%2Frss%2Fall&gateway=true Any ideas how to fix this? TIA, Jeffrey -- 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.
Frederick Cheung
2011-Apr-03 10:10 UTC
Re: Different GET response w/ wget and w/ em-http-request
On Apr 3, 5:26 am, "Jeffrey L. Taylor" <r...-f/t7CGFWhwGcvWdFBKKxig@public.gmane.org> wrote:> I am trying to fetchhttp://drdobbs.com/rss/all. With wget or Firefox, works > fine. With em-request-http, the server redirects to a login page - 302 status > code, HTML response and response LOCATION header set tohttps://login.techweb.com:443/cas/login?service=http%3A%2F%2Fdrdob > +bs.com%2Frss%2Fall&siteId=3600005&successfulLoginRedirect=http%3A%2F%2Fdrd obbs. > +com%2Frss%2Fall&gateway=true >have you tried asking em-request-http to follow redicects? Fred> Any ideas how to fix this? > > TIA, > Jeffrey-- 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.
Jeffrey L. Taylor
2011-Apr-03 12:50 UTC
Re: Re: Different GET response w/ wget and w/ em-http-request
Quoting Frederick Cheung <frederick.cheung-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>:> > > On Apr 3, 5:26 am, "Jeffrey L. Taylor" <r...-f/t7CGFWhwGcvWdFBKKxig@public.gmane.org> wrote: > > I am trying to fetchhttp://drdobbs.com/rss/all. With wget or Firefox, works > > fine. With em-request-http, the server redirects to a login page - 302 status > > code, HTML response and response LOCATION header set tohttps://login.techweb.com:443/cas/login?service=http%3A%2F%2Fdrdob > > +bs.com%2Frss%2Fall&siteId=3600005&successfulLoginRedirect=http%3A%2F%2Fdrd obbs. > > +com%2Frss%2Fall&gateway=true > > > have you tried asking em-request-http to follow redicects? >I have been following redirects manually. I''ll try enabling it in the get call. Thanks, Jeffrey -- 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.