You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cocoon.apache.org by Marco Rosella <ma...@yahoo.it> on 2004/10/29 18:13:47 UTC

repeater in another repeater

Hi! 
My problem is: it's possible put a repeater in another
repeater? 
I want to create an xml editor that create dinamically

embedding 
markups like this: 

<content> 
   <test>1 
    <test>1-1</test> 
   </test>
   <test>2 
    <test>2 -1 <test> 
    <test>2 -2 <test> 
    <test> 2 -3 
      <test>2 -3 -1</test> 
    </test> 
   </test> 
</content> 

For create first level's item, i use this repeater: 

<fd:repeater id="content"> 
  <fd:widgets> 
   <fd:field id="test"> 
    <fd:datatype base="string"/> 
   </fd:field> 
  </fd:widgets> 
</fd:repeater> 


When the user want to create a form that create a
<test> 
markup, use this button: 

<fd:repeater-action id="addtest"
action-command="add-row" repeater="content"> 
  <fd:label>:: add test ::</fd:label> 
</fd:repeater-action> 

But i don't know how to create the second level, the
third level, 
the fourth etc... 

I try this: 

<fd:repeater id="content"> 
  <fd:widgets> 
   <fd:repeater id="test"> 
    <fd:widgets> 
      <fd:field id="subtest"> 
      <fd:datatype base="string"/> 
      <fd:repeater-action id="addtest"
action-command="add- 

row" repeater="test"> 
        <fd:label>:: add sub-test ::</fd:label> 
      </fd:repeater-action>      
     </fd:field>
    </fd:widgets> 
   </fd:repeater> 
 </fd:widgets> 
</fd:repeater> 

that i hope to create a <test> form with a button to
create 
another 
<test> form and so on...but it doesn't work. 
Can you help me? 

thanks 

m_


		
___________________________________ 
Nuovo Yahoo! Messenger: E' molto più divertente: Audibles, Avatar, Webcam, Giochi, Rubrica… Scaricalo ora! 
http://it.messenger.yahoo.it

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org