I solved it...
----- Original Message -----
Sent: Thursday, April 26, 2001 11:22 AM
Subject: Taglibs - a newbie question

I'm new to taglibs, and so far it really seems like a great idea. But I cannot get the collaborating tags to work the way I want them to.
 
I want to create a html file like this
 
<%@ taglib uri="mytags" prefix="mt" %>
 
<html>
 <body>
  <table>
   <mt:getFAQ>
 
   <tr>
    <td>Datum 2001-01-01</td>
   </tr>
   
   <tr>
    <td><mt:getQuestion/></td>
   </tr>
   <tr>
    <td><mt:getAnswer/></td>
   </tr>
   </mt:getFAQ>
  </table>
 </body>
</html>
 
I cannot get the GetFAQTag to iterate...! From the GetQuestionTag ( and answer) I call
 
GetFAQTag faqparent = (GetFAQTag) findAncestorWithClass(this, GetFAQTag.class);
 
and then I call a method called faqparent.getNext(); which returns me the question or the answer.
 
I suppose I have figured out what types of tags I should use when doing this kind of tag interaction.
 
Did the tutorials on the orionserver.com but my inferior brain cannot figure out how to combine these things to do what I want, so if anyone could give me a hint I would be very grateful!
 
Thnx in advance
 
 
Johan
 
 
 

Reply via email to