Matthew Margolis
2006-Jul-22 14:27 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
Does anyone know of a fix for the issue with prototype and replacing
table rows in IE?
render :update do |page|
page.replace "row_#{params[:id]}", :partial =>
''wireless_request/wrequest'', :locals => {:wrequest =>
@wrequest}
end
This ends up making IE throw an "rjs error [object error]"
Searching around I found a couple of posts about modifying a few lines
of version 1.4 of prototype but I have 1.5.0_rc0.
Thank you,
Matthew Margolis
blog.mattmargolis.net
Peter Michaux
2006-Jul-22 15:58 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
On 7/22/06, Matthew Margolis <mrmargolis@wisc.edu> wrote:> Does anyone know of a fix for the issue with prototype and replacing > table rows in IE?Does it work in other browsers?> render :update do |page| > page.replace "row_#{params[:id]}", :partial => > ''wireless_request/wrequest'', :locals => {:wrequest => @wrequest} > end > > This ends up making IE throw an "rjs error [object error]" > > > Searching around I found a couple of posts about modifying a few lines > of version 1.4 of prototype but I have 1.5.0_rc0. > > Thank you, > Matthew Margolis > blog.mattmargolis.net > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Matthew Margolis
2006-Jul-22 16:27 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
Peter Michaux wrote:> On 7/22/06, Matthew Margolis <mrmargolis@wisc.edu> wrote: >> Does anyone know of a fix for the issue with prototype and replacing >> table rows in IE? > > Does it work in other browsers? > > > > >> render :update do |page| >> page.replace "row_#{params[:id]}", :partial => >> ''wireless_request/wrequest'', :locals => {:wrequest => @wrequest} >> end >> >> This ends up making IE throw an "rjs error [object error]" >> >> >> Searching around I found a couple of posts about modifying a few lines >> of version 1.4 of prototype but I have 1.5.0_rc0. >> >> Thank you, >> Matthew Margolis >> blog.mattmargolis.net >> _______________________________________________ >> Rails mailing list >> Rails@lists.rubyonrails.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/railsYes it works fine in Firefox but not in Internet Explorer. Matthew Margolis blog.mattmargolis.net
Geoff Hopson
2006-Jul-22 17:01 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
This might give you a clue http://wiki.rubyonrails.com/rails/pages/HowToGetAJAXUpdatesOfTablesWorkingInIE Also, go look at ajaxscaffold.com - it works cross browser there. (Apparently the innerHtml bits of <tr> are immutable in IE. Buggers). Geoff On 22/07/06, Matthew Margolis <mrmargolis@wisc.edu> wrote:> Peter Michaux wrote: > > On 7/22/06, Matthew Margolis <mrmargolis@wisc.edu> wrote: > >> Does anyone know of a fix for the issue with prototype and replacing > >> table rows in IE? > > > > Does it work in other browsers? > > > > > > > > > >> render :update do |page| > >> page.replace "row_#{params[:id]}", :partial => > >> ''wireless_request/wrequest'', :locals => {:wrequest => @wrequest} > >> end > >> > >> This ends up making IE throw an "rjs error [object error]" > >> > >> > >> Searching around I found a couple of posts about modifying a few lines > >> of version 1.4 of prototype but I have 1.5.0_rc0. > >> > >> Thank you, > >> Matthew Margolis > >> blog.mattmargolis.net > >> _______________________________________________ > >> Rails mailing list > >> Rails@lists.rubyonrails.org > >> http://lists.rubyonrails.org/mailman/listinfo/rails > >> > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > Yes it works fine in Firefox but not in Internet Explorer. > > Matthew Margolis > blog.mattmargolis.net > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Matthew Margolis
2006-Jul-22 17:22 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
Geoff Hopson wrote:> This might give you a clue > > http://wiki.rubyonrails.com/rails/pages/HowToGetAJAXUpdatesOfTablesWorkingInIE > > > Also, go look at ajaxscaffold.com - it works cross browser there. > > (Apparently the innerHtml bits of <tr> are immutable in IE. Buggers). > > Geoff > > On 22/07/06, Matthew Margolis <mrmargolis@wisc.edu> wrote: >> Peter Michaux wrote: >> > On 7/22/06, Matthew Margolis <mrmargolis@wisc.edu> wrote: >> >> Does anyone know of a fix for the issue with prototype and replacing >> >> table rows in IE? >> > >> > Does it work in other browsers? >> > >> > >> > >> > >> >> render :update do |page| >> >> page.replace "row_#{params[:id]}", :partial => >> >> ''wireless_request/wrequest'', :locals => {:wrequest => @wrequest} >> >> end >> >> >> >> This ends up making IE throw an "rjs error [object error]" >> >> >> >> >> >> Searching around I found a couple of posts about modifying a few >> lines >> >> of version 1.4 of prototype but I have 1.5.0_rc0. >> >> >> >> Thank you, >> >> Matthew Margolis >> >> blog.mattmargolis.net >> >> _______________________________________________ >> >> Rails mailing list >> >> Rails@lists.rubyonrails.org >> >> http://lists.rubyonrails.org/mailman/listinfo/rails >> >> >> > _______________________________________________ >> > Rails mailing list >> > Rails@lists.rubyonrails.org >> > http://lists.rubyonrails.org/mailman/listinfo/rails >> >> Yes it works fine in Firefox but not in Internet Explorer. >> >> Matthew Margolis >> blog.mattmargolis.net >> _______________________________________________ >> Rails mailing list >> Rails@lists.rubyonrails.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/railsIf I want to be able to update any row in the table am I going to have to put a <tbody> tag around each and every <tr>? Or do I just have to put one <tbody> tag around all the <tr>s? If it is the second way(only one <tbody>) then how would I go about referencing a particular <tr> Matthew Margolis blog.mattmargolis.net
Geoff Hopson
2006-Jul-22 17:35 UTC
[Rails] Prototype error. replace content inside a <TR> in IE
The ajaxscaffold stuff uses one tbody around the rows...each tr inside
the tbody has a unique id assigned to it eg <tr
id="address-#{address.id}"> - you can then access each row using
Ajax
goodness.
I recommend installing the ajaxscaffold plugin and looking at how he
has achieved what you are trying to do.
Good luck
Geoff
On 22/07/06, Matthew Margolis <mrmargolis@wisc.edu>
wrote:> Geoff Hopson wrote:
> > This might give you a clue
> >
> >
http://wiki.rubyonrails.com/rails/pages/HowToGetAJAXUpdatesOfTablesWorkingInIE
> >
> >
> > Also, go look at ajaxscaffold.com - it works cross browser there.
> >
> > (Apparently the innerHtml bits of <tr> are immutable in IE.
Buggers).
> >
> > Geoff
> >
> > On 22/07/06, Matthew Margolis <mrmargolis@wisc.edu> wrote:
> >> Peter Michaux wrote:
> >> > On 7/22/06, Matthew Margolis <mrmargolis@wisc.edu>
wrote:
> >> >> Does anyone know of a fix for the issue with prototype
and replacing
> >> >> table rows in IE?
> >> >
> >> > Does it work in other browsers?
> >> >
> >> >
> >> >
> >> >
> >> >> render :update do |page|
> >> >> page.replace "row_#{params[:id]}", :partial
=>
> >> >> ''wireless_request/wrequest'', :locals
=> {:wrequest => @wrequest}
> >> >> end
> >> >>
> >> >> This ends up making IE throw an "rjs error [object
error]"
> >> >>
> >> >>
> >> >> Searching around I found a couple of posts about
modifying a few
> >> lines
> >> >> of version 1.4 of prototype but I have 1.5.0_rc0.
> >> >>
> >> >> Thank you,
> >> >> Matthew Margolis
> >> >> blog.mattmargolis.net
> >> >> _______________________________________________
> >> >> Rails mailing list
> >> >> Rails@lists.rubyonrails.org
> >> >> http://lists.rubyonrails.org/mailman/listinfo/rails
> >> >>
> >> > _______________________________________________
> >> > Rails mailing list
> >> > Rails@lists.rubyonrails.org
> >> > http://lists.rubyonrails.org/mailman/listinfo/rails
> >>
> >> Yes it works fine in Firefox but not in Internet Explorer.
> >>
> >> Matthew Margolis
> >> blog.mattmargolis.net
> >> _______________________________________________
> >> Rails mailing list
> >> Rails@lists.rubyonrails.org
> >> http://lists.rubyonrails.org/mailman/listinfo/rails
> >>
> > _______________________________________________
> > Rails mailing list
> > Rails@lists.rubyonrails.org
> > http://lists.rubyonrails.org/mailman/listinfo/rails
>
> If I want to be able to update any row in the table am I going to have
> to put a <tbody> tag around each and every <tr>? Or do I just
have to
> put one <tbody> tag around all the <tr>s? If it is the second
way(only
> one <tbody>) then how would I go about referencing a particular
<tr>
>
> Matthew Margolis
> blog.mattmargolis.net
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>