Hi all, I use link_to_remote to test the ajax function on rails, however, it works fine in IE but no response on firefox (1.0.6, WindowsXP platform) I''m using rails 0.13.1. Anyone has the similar experience? Gary _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
One suggestion... Ensure that the base URL AJAX is accessing is the same with the current webpage.. e.g http://127.0.0.1:3000/ and http://localhost:3000 are different On 9/4/05, Gary Lin <garychlin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Hi all, > > I use link_to_remote to test the ajax function on rails, however, it works > fine in IE but > no response on firefox (1.0.6, WindowsXP platform) > I''m using rails 0.13.1. > > Anyone has the similar experience? > > Gary > > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >-- First they laugh at you, then they ignore you, then they fight you. Then you win. -- Mahatma Karamchand Gandhi
It works for me. On IE, Firefox and Opera. On 9/4/05, Gary Lin <garychlin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Hi all, > > I use link_to_remote to test the ajax function on rails, however, it works > fine in IE but > no response on firefox (1.0.6, WindowsXP platform) > I''m using rails 0.13.1. > > Anyone has the similar experience? > > Gary > > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Try to look to javascript console, there maybe the answer. 2005/9/4, Gary Lin <garychlin@gmail.com>:> Hi all, > > I use link_to_remote to test the ajax function on rails, however, it works > fine in IE but > no response on firefox (1.0.6, WindowsXP platform) > I'm using rails 0.13.1. > > Anyone has the similar experience? > > Gary > > > > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Well, it appears that I have a similar problem. I am having problems with a form_remote_tag in Firefox and Opera, but it works fine on IE. For some reason @params only contains the action and the controller ({"action"=>"new", "controller"=>"show"}) and none of the form parameters 2 hours later, after debugging prototype.js I got the picture. Form.getElements uses "form.getElementsByTagName" which does not work as expected in an unfortunate case (well, my case) If for the sake of alignment you use a table to arrange the form fields, this will NOT work: <table> <form> <tr><td><input_field1></td></tr> <tr><td><input_field2></td></tr> </form> </table> The reason is that form.getElementsByTagName("input") would return 0, and not 2 as one would expect. To fix that, you have to do it like: <form> <table> <tr><td><input_field1></td></tr> <tr><td><input_field2></td></tr> </table> </form> Hopefully this will save someone''s hours next time ;) bogdan On 9/4/05, pepe <damn.pepe-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Try to look to javascript console, there maybe the answer. > > 2005/9/4, Gary Lin <garychlin-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>: > > Hi all, > > > > I use link_to_remote to test the ajax function on rails, however, it > works > > fine in IE but > > no response on firefox (1.0.6, WindowsXP platform) > > I''m using rails 0.13.1. > > > > Anyone has the similar experience? > > > > Gary > > > > > > > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > > > > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails > > >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
> If for the sake of alignment you use a table to arrange the formfields, this will NOT work:> <table> > <form> > <tr><td><input_field1></td></tr> > <tr><td><input_field2></td></tr> > </form> > </table>Well I''m not surprised, it''s invalid HTML. Don''t expect your DOM scripts to be reliable if your HTML isn''t in order. Cheers Luke _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails