Hi,
I use link_to_remote to create a link to trigger an
ajax, things work fine, a new rhtml is created,
however, the newly created rhtml doesn''t replace my
old zone, it shows instead on top of my old
zone...Does someone know why???
my code is like
<table>
<tr><td colspan="2"><a href="#"
onclick="new
Ajax.Updater(''zone1'',
''/atlasmain/updateTissueAndTreatment'',
{asynchronous:true, evalScripts:true}); return
false;">Reset All</a></td></tr>
<tr>
<div id="zone1">
<td>titi</td>
<td>tata</td>
</div>
</tr>
</table>
Thanks you very much
Saiho
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
You have to replace a whole block.. not a tr or a td.. the whole table. pmt Saiho sayoyo wrote:> <table> > <tr><td colspan="2"><a href="#" onclick="new > Ajax.Updater(''zone1'', > ''/atlasmain/updateTissueAndTreatment'', > {asynchronous:true, evalScripts:true}); return > false;">Reset All</a></td></tr> > <tr> > <div id="zone1"> > <td>titi</td> > <td>tata</td> > </div> > </tr> > </table>-- Posted via http://www.ruby-forum.com/.
Saiho--
Actually you can simply replace a row if you like in your table:
<tr>
<tbody id="new_row"></tbody>
</tr>
~d
On 3/2/06, pmt <pmt@tecsas.fr> wrote:>
> You have to replace a whole block.. not a tr or a td.. the whole table.
>
> pmt
>
> Saiho sayoyo wrote:
> > <table>
> > <tr><td colspan="2"><a href="#"
onclick="new
> > Ajax.Updater(''zone1'',
> > ''/atlasmain/updateTissueAndTreatment'',
> > {asynchronous:true, evalScripts:true}); return
> > false;">Reset All</a></td></tr>
> > <tr>
> > <div id="zone1">
> > <td>titi</td>
> > <td>tata</td>
> > </div>
> > </tr>
> > </table>
>
> --
> Posted via http://www.ruby-forum.com/.
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/f8af4c4d/attachment.html
Actually, I don''t think <tbody> is valid inside a <tr> tag... only <td> or <th>. You''d want to replace the <tr>. Not sure how well all the browsers deal with that though... b Damon Hill wrote:> Saiho-- > > Actually you can simply replace a row if you like in your table: > > <tr> > <tbody id="new_row"></tbody> > </tr> > > ~d > > > On 3/2/06, *pmt* <pmt@tecsas.fr <mailto:pmt@tecsas.fr>> wrote: > > You have to replace a whole block.. not a tr or a td.. the whole table. > > pmt > > Saiho sayoyo wrote: > > <table> > > <tr><td colspan="2"><a href="#" onclick="new > > Ajax.Updater(''zone1'', > > ''/atlasmain/updateTissueAndTreatment'', > > {asynchronous:true, evalScripts:true}); return > > false;">Reset All</a></td></tr> > > <tr> > > <div id="zone1"> > > <td>titi</td> > > <td>tata</td> > > </div> > > </tr> > > </table> > > -- > Posted via http://www.ruby-forum.com/. > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org <mailto: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
In Firefox 1.+ and IE 6.+ the below code works quite nicely. Other browsers, I am not sure as they are not a requirement of the current project I have it implemented for. Thanks, ~d On 3/2/06, Ben Munat <bent@munat.com> wrote:> > Actually, I don''t think <tbody> is valid inside a <tr> tag... only <td> or > <th>. You''d > want to replace the <tr>. Not sure how well all the browsers deal with > that though... > > b > > Damon Hill wrote: > > Saiho-- > > > > Actually you can simply replace a row if you like in your table: > > > > <tr> > > <tbody id="new_row"></tbody> > > </tr> > > > > ~d > > > > > > On 3/2/06, *pmt* <pmt@tecsas.fr <mailto:pmt@tecsas.fr>> wrote: > > > > You have to replace a whole block.. not a tr or a td.. the whole > table. > > > > pmt > > > > Saiho sayoyo wrote: > > > <table> > > > <tr><td colspan="2"><a href="#" onclick="new > > > Ajax.Updater(''zone1'', > > > ''/atlasmain/updateTissueAndTreatment'', > > > {asynchronous:true, evalScripts:true}); return > > > false;">Reset All</a></td></tr> > > > <tr> > > > <div id="zone1"> > > > <td>titi</td> > > > <td>tata</td> > > > </div> > > > </tr> > > > </table> > > > > -- > > Posted via http://www.ruby-forum.com/. > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org <mailto: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 > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060302/9f4dd4d1/attachment.html
Thanks you very much for the information:)!!!! --- Damon Hill <mdamonhill@gmail.com> wrote:> Saiho-- > > Actually you can simply replace a row if you like in > your table: > > <tr> > <tbody id="new_row"></tbody> > </tr> > > ~d > > > On 3/2/06, pmt <pmt@tecsas.fr> wrote: > > > > You have to replace a whole block.. not a tr or a > td.. the whole table. > > > > pmt > > > > Saiho sayoyo wrote: > > > <table> > > > <tr><td colspan="2"><a href="#" onclick="new > > > Ajax.Updater(''zone1'', > > > ''/atlasmain/updateTissueAndTreatment'', > > > {asynchronous:true, evalScripts:true}); return > > > false;">Reset All</a></td></tr> > > > <tr> > > > <div id="zone1"> > > > <td>titi</td> > > > <td>tata</td> > > > </div> > > > </tr> > > > </table> > > > > -- > > Posted via http://www.ruby-forum.com/. > > _______________________________________________ > > 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 >The mind is its own place, and in itself. Can make a Heaven of Hell, a Hell of Heaven. http://www.geocities.com/sayoyo/ __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com
"work" != "valid" b Damon Hill wrote:> In Firefox 1.+ and IE 6.+ the below code works quite nicely. > Other browsers, I am not sure as they are not a requirement of the > current project I have it implemented for. > > Thanks, > ~d > > On 3/2/06, *Ben Munat* <bent@munat.com <mailto:bent@munat.com>> wrote: > > Actually, I don''t think <tbody> is valid inside a <tr> tag... only > <td> or <th>. You''d > want to replace the <tr>. Not sure how well all the browsers deal > with that though... > > b > > Damon Hill wrote: > > Saiho-- > > > > Actually you can simply replace a row if you like in your table: > > > > <tr> > > <tbody id="new_row"></tbody> > > </tr> > > > > ~d > > > > > > On 3/2/06, *pmt* <pmt@tecsas.fr <mailto:pmt@tecsas.fr> > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr>>> wrote: > > > > You have to replace a whole block.. not a tr or a td.. the > whole table. > > > > pmt > > > > Saiho sayoyo wrote: > > > <table> > > > <tr><td colspan="2"><a href="#" onclick="new > > > Ajax.Updater (''zone1'', > > > ''/atlasmain/updateTissueAndTreatment'', > > > {asynchronous:true, evalScripts:true}); return > > > false;">Reset All</a></td></tr> > > > <tr> > > > <div id="zone1"> > > > <td>titi</td> > > > <td>tata</td> > > > </div> > > > </tr> > > > </table> > > > > -- > > Posted via http://www.ruby-forum.com/. > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org> > <mailto:Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org>> > > http://lists.rubyonrails.org/mailman/listinfo/rails > <http://lists.rubyonrails.org/mailman/listinfo/rails> > > > > > > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org <mailto:Rails@lists.rubyonrails.org> > > http://lists.rubyonrails.org/mailman/listinfo/rails > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org <mailto: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
Ben-- Can you please define what you mean by valid? In Firefox using the HTMLValidation plugin, the page is valid. I don''t know what else I need to do to make this "valid". Thanks, ~d On 3/2/06, Ben Munat <bent@munat.com> wrote:> > "work" != "valid" > > b > > Damon Hill wrote: > > In Firefox 1.+ and IE 6.+ the below code works quite nicely. > > Other browsers, I am not sure as they are not a requirement of the > > current project I have it implemented for. > > > > Thanks, > > ~d > > > > On 3/2/06, *Ben Munat* <bent@munat.com <mailto:bent@munat.com>> wrote: > > > > Actually, I don''t think <tbody> is valid inside a <tr> tag... only > > <td> or <th>. You''d > > want to replace the <tr>. Not sure how well all the browsers deal > > with that though... > > > > b > > > > Damon Hill wrote: > > > Saiho-- > > > > > > Actually you can simply replace a row if you like in your table: > > > > > > <tr> > > > <tbody id="new_row"></tbody> > > > </tr> > > > > > > ~d > > > > > > > > > On 3/2/06, *pmt* <pmt@tecsas.fr <mailto:pmt@tecsas.fr> > > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr>>> wrote: > > > > > > You have to replace a whole block.. not a tr or a td.. the > > whole table. > > > > > > pmt > > > > > > Saiho sayoyo wrote: > > > > <table> > > > > <tr><td colspan="2"><a href="#" onclick="new > > > > Ajax.Updater (''zone1'', > > > > ''/atlasmain/updateTissueAndTreatment'', > > > > {asynchronous:true, evalScripts:true}); return > > > > false;">Reset All</a></td></tr> > > > > <tr> > > > > <div id="zone1"> > > > > <td>titi</td> > > > > <td>tata</td> > > > > </div> > > > > </tr> > > > > </table> > > > > > > -- > > > Posted via http://www.ruby-forum.com/. > > > _______________________________________________ > > > Rails mailing list > > > Rails@lists.rubyonrails.org > > <mailto:Rails@lists.rubyonrails.org> > > <mailto:Rails@lists.rubyonrails.org > > <mailto:Rails@lists.rubyonrails.org>> > > > http://lists.rubyonrails.org/mailman/listinfo/rails > > <http://lists.rubyonrails.org/mailman/listinfo/rails> > > > > > > > > > > > > > > > ------------------------------------------------------------------------ > > > > > > _______________________________________________ > > > Rails mailing list > > > Rails@lists.rubyonrails.org <mailto:Rails@lists.rubyonrails.org> > > > http://lists.rubyonrails.org/mailman/listinfo/rails > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org <mailto: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 > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org > http://lists.rubyonrails.org/mailman/listinfo/rails >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://wrath.rubyonrails.org/pipermail/rails/attachments/20060303/8b1d28a2/attachment.html
Damon Hill wrote:> Ben-- > > Can you please define what you mean by valid? > In Firefox using the HTMLValidation plugin, the page is valid. > I don''t know what else I need to do to make this "valid".Really? Well maybe I have some bad info then... What I found online was that the only valid children of <tr> are <td> and <th>. Did you try running the page through the w3c validator? (http://validator.w3.org/) Maybe there are some settings in the plugin that''s allowing this to pass? I just tried taking a valid xhtml 1.0 transitional page and adding "<table><tr><tbody>some stuff</tbody></tr></table>" to it and the validator complains that <tbody> is not in a valid location, nor is the text inside it valid. b> > Thanks, > ~d > > On 3/2/06, *Ben Munat* <bent@munat.com <mailto:bent@munat.com>> wrote: > > "work" != "valid" > > b > > Damon Hill wrote: > > In Firefox 1.+ and IE 6.+ the below code works quite nicely. > > Other browsers, I am not sure as they are not a requirement of the > > current project I have it implemented for. > > > > Thanks, > > ~d > > > > On 3/2/06, *Ben Munat* <bent@munat.com <mailto:bent@munat.com> > <mailto:bent@munat.com <mailto:bent@munat.com>>> wrote: > > > > Actually, I don''t think <tbody> is valid inside a <tr> tag... > only > > <td> or <th>. You''d > > want to replace the <tr>. Not sure how well all the browsers deal > > with that though... > > > > b > > > > Damon Hill wrote: > > > Saiho-- > > > > > > Actually you can simply replace a row if you like in your > table: > > > > > > <tr> > > > <tbody id="new_row"></tbody> > > > </tr> > > > > > > ~d > > > > > > > > > On 3/2/06, *pmt* <pmt@tecsas.fr <mailto:pmt@tecsas.fr> > <mailto: pmt@tecsas.fr <mailto:pmt@tecsas.fr>> > > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr> > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr>>>> wrote: > > > > > > You have to replace a whole block.. not a tr or a td.. > the > > whole table. > > > > > > pmt > > > > > > Saiho sayoyo wrote: > > > > <table> > > > > <tr><td colspan="2"><a href="#" onclick="new > > > > Ajax.Updater (''zone1'', > > > > ''/atlasmain/updateTissueAndTreatment'', > > > > {asynchronous:true, evalScripts:true}); return > > > > false;">Reset All</a></td></tr> > > > > <tr> > > > > <div id="zone1"> > > > > <td>titi</td> > > > > <td>tata</td> > > > > </div> > > > > </tr> > > > > </table> > > > > > > -- > > > Posted via http://www.ruby-forum.com/ > <http://www.ruby-forum.com/>. > > > _______________________________________________ > > > Rails mailing list > > > Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org> > > <mailto: Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org>> > > <mailto:Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org> > > <mailto: Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org>>> > > > http://lists.rubyonrails.org/mailman/listinfo/rails > > < http://lists.rubyonrails.org/mailman/listinfo/rails> > > > > > > > > > > > > > > > ------------------------------------------------------------------------ > > > > > > _______________________________________________ > > > Rails mailing list > > > Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org> <mailto: > Rails@lists.rubyonrails.org <mailto:Rails@lists.rubyonrails.org>> > > > http://lists.rubyonrails.org/mailman/listinfo/rails > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org> > <mailto:Rails@lists.rubyonrails.org > <mailto:Rails@lists.rubyonrails.org>> > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > > > > > > > ------------------------------------------------------------------------ > > > > > _______________________________________________ > > Rails mailing list > > Rails@lists.rubyonrails.org <mailto:Rails@lists.rubyonrails.org> > > http://lists.rubyonrails.org/mailman/listinfo/rails > _______________________________________________ > Rails mailing list > Rails@lists.rubyonrails.org <mailto: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
Ben--
I am not sure why it isn''t complaining about the <tdbody> it
could be that
the plugin is indeed "fixing" the problem.
Beats me.
What happens in my case is the
<tdbody></tdbody>
is replaced by a lot of <td> data when the ajax action is completed.
maybe the resulting page is valid??
thanks,
~damon
On 3/3/06, Ben Munat <bent@munat.com> wrote:>
> Damon Hill wrote:
> > Ben--
> >
> > Can you please define what you mean by valid?
> > In Firefox using the HTMLValidation plugin, the page is valid.
> > I don''t know what else I need to do to make this
"valid".
>
> Really? Well maybe I have some bad info then... What I found online was
> that the only
> valid children of <tr> are <td> and <th>. Did you try
running the page
> through the w3c
> validator? (http://validator.w3.org/) Maybe there are some settings in the
> plugin that''s
> allowing this to pass?
>
> I just tried taking a valid xhtml 1.0 transitional page and adding
> "<table><tr><tbody>some
> stuff</tbody></tr></table>" to it and the validator
complains that <tbody>
> is not in a
> valid location, nor is the text inside it valid.
>
> b
>
> >
> > Thanks,
> > ~d
> >
> > On 3/2/06, *Ben Munat* <bent@munat.com
<mailto:bent@munat.com>> wrote:
> >
> > "work" != "valid"
> >
> > b
> >
> > Damon Hill wrote:
> > > In Firefox 1.+ and IE 6.+ the below code works quite nicely.
> > > Other browsers, I am not sure as they are not a requirement
of
> the
> > > current project I have it implemented for.
> > >
> > > Thanks,
> > > ~d
> > >
> > > On 3/2/06, *Ben Munat* <bent@munat.com
<mailto:bent@munat.com>
> > <mailto:bent@munat.com <mailto:bent@munat.com>>>
wrote:
> > >
> > > Actually, I don''t think <tbody> is valid
inside a <tr> tag...
> > only
> > > <td> or <th>. You''d
> > > want to replace the <tr>. Not sure how well all
the browsers
> deal
> > > with that though...
> > >
> > > b
> > >
> > > Damon Hill wrote:
> > > > Saiho--
> > > >
> > > > Actually you can simply replace a row if you like
in your
> > table:
> > > >
> > > > <tr>
> > > > <tbody
id="new_row"></tbody>
> > > > </tr>
> > > >
> > > > ~d
> > > >
> > > >
> > > > On 3/2/06, *pmt* <pmt@tecsas.fr
<mailto:pmt@tecsas.fr>
> > <mailto: pmt@tecsas.fr <mailto:pmt@tecsas.fr>>
> > > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr>
> > <mailto:pmt@tecsas.fr <mailto:pmt@tecsas.fr>>>>
wrote:
> > > >
> > > > You have to replace a whole block.. not a tr
or a td..
> > the
> > > whole table.
> > > >
> > > > pmt
> > > >
> > > > Saiho sayoyo wrote:
> > > > > <table>
> > > > > <tr><td
colspan="2"><a href="#" onclick="new
> > > > > Ajax.Updater (''zone1'',
> > > > >
''/atlasmain/updateTissueAndTreatment'',
> > > > > {asynchronous:true, evalScripts:true});
return
> > > > > false;">Reset
All</a></td></tr>
> > > > > <tr>
> > > > > <div id="zone1">
> > > > > <td>titi</td>
> > > > > <td>tata</td>
> > > > > </div>
> > > > > </tr>
> > > > > </table>
> > > >
> > > > --
> > > > Posted via http://www.ruby-forum.com/
> > <http://www.ruby-forum.com/>.
> > > >
_______________________________________________
> > > > Rails mailing list
> > > > Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>
> > > <mailto: Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>>
> > > <mailto:Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>
> > > <mailto: Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>>>
> > > >
http://lists.rubyonrails.org/mailman/listinfo/rails
> > > <
http://lists.rubyonrails.org/mailman/listinfo/rails>
> > > >
> > > >
> > > >
> > > >
> > >
> >
> ------------------------------------------------------------------------
> > > >
> > > > _______________________________________________
> > > > Rails mailing list
> > > > Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org> <mailto:
> > Rails@lists.rubyonrails.org
<mailto:Rails@lists.rubyonrails.org>>
> > > >
http://lists.rubyonrails.org/mailman/listinfo/rails
> > > _______________________________________________
> > > Rails mailing list
> > > Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>
> > <mailto:Rails@lists.rubyonrails.org
> > <mailto:Rails@lists.rubyonrails.org>>
> > > http://lists.rubyonrails.org/mailman/listinfo/rails
> > >
> > >
> > >
> > >
> >
> ------------------------------------------------------------------------
> >
> > >
> > > _______________________________________________
> > > Rails mailing list
> > > Rails@lists.rubyonrails.org
<mailto:Rails@lists.rubyonrails.org>
> > > http://lists.rubyonrails.org/mailman/listinfo/rails
> > _______________________________________________
> > Rails mailing list
> > Rails@lists.rubyonrails.org
<mailto: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
> _______________________________________________
> Rails mailing list
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL:
http://wrath.rubyonrails.org/pipermail/rails/attachments/20060303/846c951f/attachment.html