Eric:

You are comparing a reference of a String and a String
by itself.

You are doing the following: referenceA.equals(null)
You should do: referenceA.equals(referenceB)

Both referenceA and referenceB must be String
references.

But, I think that what you want to do is:
  request.getParameter("...").equals("otherString")
  or
  request.getParameter("...") == null

request.getParameter() gives you a reference, so you
should treat it as if. Hope this helps

Atilio



--- Eric Cho <[EMAIL PROTECTED]> wrote:
> Hi,
> I'm new to jsps and to java itself so bear with me.
> what am i doing wrong with this?
>
> <%
>         if
> (request.getParameter("link").equals(null)){ %>
>
>         <jsp:include page="mainMenu.jsp"
> flush="true" />
>
> <%} else { %>
>
>         <jsp:include page="<%=
> request.getParameter("link"); %>"
> flush="true" />
>
> <% } %>
>
> thanks,
>
> Eric
>
_______________________________________________________
> eSafe Protect Gateway has scanned this mail for
> viruses, vandals and
> suspicious attachments.
>
>
===========================================================================
> 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


__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/

===========================================================================
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