Hi (again),
as I'm still working on some problem described on this mailing list at
the 18th of May, subject "Hide/show columns in an ajaxified table
cform", I have now found some weird Cocoon behaviour:
My repeater rows are nested not in DIVs but in table tags. When using
Ajax removing a repeater row (visually a table column) the bu:update
result contains SPANs. When this only looks ugly in the browser it looks
really weird when adding a (table) row - the bu:update contains SPANs
mixed with table elements...
Everything is fine with Ajax off but I don't want to miss Web 2.0 ;-)
:-?
Florian
---- template code excerpt (beat me, it's rather long... ----
<ft:form-template action="showQuestion" method="POST" ajax="true">
<input type="hidden" name="continuation-id" value="${continuation.id}"/>
<ft:widget id="questionID"/>
<div id="questionAnswerContainer">
<ft:widget id="locales"/>
<table border="1">
<thead>
<ft:repeater id="questionLocaleRepeater">
<tr>
<th/>
<ft:repeater-rows>
<th>
<ft:widget id="hideLocale">
<fi:styling type="image"
src="images/close.gif"/>
</ft:widget>
<ft:widget id="questionLocale"/>
</th>
</ft:repeater-rows>
<th/>
</tr>
</ft:repeater>
<ft:repeater id="questionDataRepeater">
<tr>
<th/>
<ft:repeater-rows>
<th>
<ft:widget id="questionData"
fi:type="inplace" dojoType="inlineEditBox"/>
</th>
</ft:repeater-rows>
<th/>
</tr>
</ft:repeater>
</thead>
<ft:repeater id="answerRepeater">
<tbody>
<ft:repeater-rows>
<tr>
<td>
<ft:widget id="answerCorrect"/>
</td>
<ft:repeater id="answerDataRepeater">
<ft:repeater-rows>
<td class="${answerLocale}">
<ft:widget id="answerData"
fi:type="inplace" dojoType="inlineEditBox"/>
</td>
</ft:repeater-rows>
</ft:repeater>
<td>
<ft:widget id="deleteAnswer">
<fi:styling type="image"
src="images/trash.gif"/>
</ft:widget>
</td>
</tr>
</ft:repeater-rows>
</tbody>
</ft:repeater>
</table>
----- bu:update sent by Cocoon after "column deletion" (hideLocale) -----
<bu:document xmlns:bu="http://apache.org/cocoon/browser-update/1.0">
<bu:replace id="questionLocaleRepeater.1">
<span id="questionLocaleRepeater.1" />
</bu:replace>
<bu:replace id="questionDataRepeater.1">
<span id="questionDataRepeater.1" />
</bu:replace>
<bu:replace id="answerRepeater.0.answerDataRepeater.1">
<span id="answerRepeater.0.answerDataRepeater.1" />
</bu:replace>
<bu:replace id="answerRepeater.1.answerDataRepeater.1">
<span id="answerRepeater.1.answerDataRepeater.1" />
</bu:replace>
<bu:replace id="answerRepeater.2.answerDataRepeater.1">
<span id="answerRepeater.2.answerDataRepeater.1" />
</bu:replace>
</bu:document>
---- bu:update excerpt after "row adding" ----
<bu:document xmlns:bu="http://apache.org/cocoon/browser-update/1.0">
<bu:replace id="answerRepeater">
<tbody id="answerRepeater">
<tr id="answerRepeater.0">
<td>
<span id="answerRepeater.0.answerCorrect">
<input title="" name="answerRepeater.0.answerCorrect" value="true"
type="checkbox" id="answerRepeater.0.answerCorrect:input" class="forms
booleanfield active" />
</span>
</td>
<td class="" id="answerRepeater.0.answerDataRepeater.0">
<span id="answerRepeater.0.answerDataRepeater.0.answerData">
<span
onSave="dojo.byId('answerRepeater.0.answerDataRepeater.0.answerData:input').value
= arguments[0];" dojoType="InlineEditBox">
Donald Duck
</span>
<input value="Donald Duck"
name="answerRepeater.0.answerDataRepeater.0.answerData" type="hidden"
id="answerRepeater.0.answerDataRepeater.0.answerData:input" />
</span>
</td>
<span id="answerRepeater.0.answerDataRepeater.1" />
<td class="" id="answerRepeater.0.answerDataRepeater.2">
...
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]