I think you have to drop out of JSP script before the include directive and
the drop
back in before the else statement, such as
if (flag == 1)
%>
<%@ include file="a.jsp" %>
<%
else if (flag == 2) ...

-----Original Message-----
From: Warty, Koustubh [mailto:[EMAIL PROTECTED]]
Sent: Thursday, September 13, 2001 2:01 PM
To: [EMAIL PROTECTED]
Subject: Include tag in a conditional statement works ??


 Hello,
  What is I have to do something like this that according to a particular
value I have to change the header of each page ? I tried using the "include"
but does not work as it does not work in a conditional statement like

 if (flag == 1)
  <%@ include file="a.jsp" %>
 else if (flag == 2)
    <%@ include file="b.jsp" %>
  else
   <%@ include file="c.jsp" %>

 Is this possible ? Else what else can I do ?

 Thanks,
  - Koustubh



===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST
DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".
Some relevant FAQs on JSP/Servlets can be found at:

 http://java.sun.com/products/jsp/faq.html
 http://www.esperanto.org.nz/jsp/jspfaq.html
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
 http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets

Reply via email to