Any ideas?
Paulo Ramos Jesse Kuhnert escreveu:
Even if you were somehow able to make it work the way you wanted thatparticular application would never work in IE. IE won't allow you to update tr elements like that - you can update data within a td element but that'sabout it. On 5/30/07, Paulo Ramos <[EMAIL PROTECTED]> wrote:Hi, I have a table with a DirectLink's that must get more information from the corresponding line and show them in that line. I am trying to do that with ajax but the response is rendered inside the corresponding tag and the id is incremented. Example: when i try to update the tag with id=2 from line 2 this is rendered like that: <div id="2"> <div id="3"> bla bla bla </div </div> When i tried something more simple that i found in a previous post i get the same problem. When i click the second line the response is rendered inside the <tr> tag including another <tr> like this: <tr id="therow_0"> <tr id="therow_1"> <td> 8330 </td> <td> <a id="DirectLink_1"href="/eLoja/tables/TesteAjaxFor,$DirectLink.sdirect?sp=2&updateParts=therow_1">Update "therow_1" </a> </td> </tr> </tr> <tr id="For_1"/> .... </tr> Can anyone help me? Thaks, Paulo Ramos My example code: TesteAjaxFor.html : ------------------------------------------------ <html> <head><title>Teste Tabela</title></head> <body jwcid="@Border"> <div id="content"> <div id="head_formulario"> <div class="head_form">Listagem</div> </div> <br> <center> <table border="1" cellpadding="5"> <tr jwcid="@For" source="ognl:rows" value="ognl:row" index="ognl:theIndex"> <tr jwcid="[EMAIL PROTECTED]"> <td> <span jwcid="@Insert" value="ognl:row"> </span> </td> <td> <a jwcid="@DirectLink" listener="listener:aListener" async="true" parameters="ognl:{theIndex}"updateComponents="ognl:components.therow.clientId"> Update "<span jwcid="@Insert" value="ognl:components.therow.clientId"> </span>" </a> </td> </tr> </tr> </table> </center> <div id="botao"> </div> </div> </body> </html> TesteAjaxFor.java : ----------------------------------------------- public abstract class TesteAjaxFor extends BasePage implements PageBeginRenderListener { @Persist public abstract String[] getRows(); public abstract void setRows(String[] rows); public abstract String getRow(); public abstract int getTheIndex(); public void pageBeginRender(PageEvent e) { if (getRows() == null){ setRows(new String[] {"foo", "bar", "baz"}); } } public void aListener(IRequestCycle cycle, int idx) { getRows()[idx] = "" + (int)(Math.random()*10000); } }
smime.p7s
Description: S/MIME Cryptographic Signature