Strange. I can successfully define a very simple recursivejsp page:

{begin recursive.jsp}
        Hello World
        <jsp:include page="recursive.jsp" flush="true"/>
{begin recursive.jsp}

This works fine (other than crashing the container of course!). I'm using
Tomcat 4 inside JBoss 3.2.3.

looking at the generted servlet source I can see that the <jsp:include/> is
rendered as:

        JspRuntimeLibrary.include(request, response, "recursive.jsp", out,
true);

So, I don't think there is any fundamental problem with using recurive,
dynamic jsp includes.

I'd check the spelling etc. in your code & try again. Then simplify your jsp
as far as you can  - remove your recusrsion checks and just let the
container fall over. If you are still having problems then I can send you a
custom tag which implements include functionality - this might help with
debugging.

Paul


> -----Original Message-----
> From: terry Highfield [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, August 18, 2004 5:11 PM
> To: [EMAIL PROTECTED]
> Subject: RE: Recursive pages
> 
> 
> Cheers Paul,
> 
> I went down this path also,
> 
> I tried jsp:include but this was ignore by tomcat. So much 
> ignored infact 
> the the <jsp:incluse bit is not included in the source - it is just 
> completly ignored.
> 
> Have you any suggestion on this?
> 
> Thank you,
> 
> Terry
> 
> 
> >From: Paul McCulloch <[EMAIL PROTECTED]>
> >Reply-To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
> >To: 'Struts Users Mailing List' <[EMAIL PROTECTED]>
> >Subject: RE: Recursive pages
> >Date: Wed, 18 Aug 2004 09:43:32 +0100
> >
> >I think the problem is that you are using a static include. 
> This is an
> >instruction to the jsp -> java compiler that, you want to include the
> >current *page source* within itself!
> >
> >You say you get a recursive loop - I'm surprised. I would 
> expect that this
> >wouldn't compile at all - are you sure yuo get a .java file 
> & a .class file
> >for your JSP?
> >
> >I think that using a dynamic include (<jsp:include/>) has a 
> better chance 
> >of
> >working. This works as an instruction to include the 
> *results* of the use 
> >of
> >your page.
> >
> >Of course I could be entirely wrong about all of this :-)
> >
> >Paul
> >
> > > -----Original Message-----
> > > From: terry Highfield [mailto:[EMAIL PROTECTED]
> > > Sent: Wednesday, August 18, 2004 12:26 AM
> > > To: [EMAIL PROTECTED]
> > > Subject: Recursive pages
> > >
> > >
> > > Hi all,
> > >
> > > Does anyone know how to make recursive jsp pages?
> > >
> > > I believe this can be done using <%@ include 
> file="recursive.jsp" %>
> > >
> > > I have done this as :-
> > >
> > > <nested:present property="replies" >
> > >    <nested:iterate property="replies">
> > >        <%@ include file="recursive.jsp" %>
> > >    </nested:iterate>
> > > </nested:present>
> > > The above code is actually in recursive.jsp
> > >
> > > The bean behind this has a structure :
> > >
> > > class Message implements Serializable {
> > >     int id
> > >     String subject
> > >     String messageText
> > >     ArrayList replies     // Message objects
> > >
> > > }
> > >
> > > Not all messages have replies so this become likes a tree ADT
> > > - hence the
> > > need for recursion.
> > >
> > >
> > > All I get is a recursive loop!
> > >
> > > I did try using tiles but with this I get the error "Cannot
> > > flush within a
> > > custom tag" (even when I set flush to false), strange it only
> > > complains when
> > > within an iterate loop and equally annoying due to  the fact
> > > that I need to
> > > do it within an iterate loop.
> > >
> > > This has been bugging me on and off for a week now and so any
> > > help would be
> > > greatly appreciated - thank you.
> > >
> > >
> > > Terry.
> > > aka: Ingenious Monkey
> > >
> > > _________________________________________________________________
> > > Want to block unwanted pop-ups? Download the free MSN Toolbar now!
> > > http://toolbar.msn.co.uk/
> > >
> > >
> > > 
> ---------------------------------------------------------------------
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: [EMAIL PROTECTED]
> > >
> >
> >
> >*************************************************************
> *********
> >Axios Email Confidentiality Footer
> >Privileged/Confidential Information may be contained in this 
> message. If 
> >you are not the addressee indicated in this message (or 
> responsible for 
> >delivery of the message to such person), you may not copy or 
> deliver this 
> >message to anyone. In such case, you should destroy this 
> message, and 
> >notify us immediately. If you or your employer does not 
> consent to Internet 
> >email messages of this kind, please advise us immediately. Opinions, 
> >conclusions and other information expressed in this message 
> are not given 
> >or endorsed by my Company or employer unless otherwise 
> indicated by an 
> >authorised representative independent of this message.
> >WARNING:
> >While Axios Systems Ltd takes steps to prevent computer 
> viruses from being 
> >transmitted via electronic mail attachments we cannot guarantee that 
> >attachments do not contain computer virus code.  You are 
> therefore strongly 
> >advised to undertake anti virus checks prior to accessing 
> the attachment to 
> >this electronic mail.  Axios Systems Ltd grants no 
> warranties regarding 
> >performance use or quality of any attachment and undertakes 
> no liability 
> >for loss or damage howsoever caused.
> >*************************************************************
> *********
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> 
> _________________________________________________________________
> Express yourself with cool new emoticons 
http://www.msn.co.uk/specials/myemo


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


**********************************************************************
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you are not 
the addressee indicated in this message (or responsible for delivery of the message to 
such person), you may not copy or deliver this message to anyone. In such case, you 
should destroy this message, and notify us immediately. If you or your employer does 
not consent to Internet email messages of this kind, please advise us immediately. 
Opinions, conclusions and other information expressed in this message are not given or 
endorsed by my Company or employer unless otherwise indicated by an authorised 
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being transmitted 
via electronic mail attachments we cannot guarantee that attachments do not contain 
computer virus code.  You are therefore strongly advised to undertake anti virus 
checks prior to accessing the attachment to this electronic mail.  Axios Systems Ltd 
grants no warranties regarding performance use or quality of any attachment and 
undertakes no liability for loss or damage howsoever caused.
**********************************************************************


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to