I''m getting the above error and i''m not sure why. Here is the code i''m calling. This is in a custom js file that is attached after the prototype library. function avtf(u,v) { //AjaxMethods.addVenueToFavorites(u,v, function(str) { alert(str); }); return false; alert(''about to run ajax''); new Ajax.Request(''/AddVenueToFavorites'', { method: ''get'', parameters: {venueId: v, userId: u}, onComplete: complete }); } function complete(o) { alert(''Complete''); } the 1st alert runs fine, but then i get that error. Any ideas? This AddVenueToFavorites is a servlet. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
Hi, That code won''t compile (hence the error), the first line of the function is commented-out (see the // just before AjaxMethods) which is probably the problem. -- T.J. Crowder tj / crowder software / com On May 1, 5:01 pm, IlyaE <ilyaelk...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I''m getting the above error and i''m not sure why. > Here is the code i''m calling. This is in a custom js file that is > attached after the prototype library. > > function avtf(u,v) { > //AjaxMethods.addVenueToFavorites(u,v, function(str) > { alert(str); }); return false; > alert(''about to run ajax''); > new Ajax.Request(''/AddVenueToFavorites'', { method: ''get'', parameters: > {venueId: v, userId: u}, onComplete: complete }); > > } > > function complete(o) { > alert(''Complete''); > > } > > the 1st alert runs fine, but then i get that error. Any ideas? This > AddVenueToFavorites is a servlet.--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---
actually, i found the problem... the comment is fine as it was my previous work. I realized the /AddVenueToFavorites servlet call was not including the context path.. aka it was trying to call localhost: 808/AddVenue.... On May 2, 6:28 am, "T.J. Crowder" <tjcrow...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi, > > That code won''t compile (hence the error), the first line of the > function is commented-out (see the // just before AjaxMethods) which > is probably the problem. > -- > T.J. Crowder > tj / crowder software / com > > On May 1, 5:01 pm, IlyaE <ilyaelk...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: > > > > > I''m getting the above error and i''m not sure why. > > Here is the code i''m calling. This is in a custom js file that is > > attached after the prototype library. > > > function avtf(u,v) { > > //AjaxMethods.addVenueToFavorites(u,v, function(str) > > { alert(str); }); return false; > > alert(''about to run ajax''); > > new Ajax.Request(''/AddVenueToFavorites'', { method: ''get'', parameters: > > {venueId: v, userId: u}, onComplete: complete }); > > > } > > > function complete(o) { > > alert(''Complete''); > > > } > > > the 1st alert runs fine, but then i get that error. Any ideas? This > > AddVenueToFavorites is a servlet.- Hide quoted text - > > - Show quoted text ---~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs?hl=en -~----------~----~----~----~------~----~------~--~---