Hi Nitin,
your code is buggy.
> <%if(request.getParameter("usrName") != null)
> {
> out.println(request.getParameter("usrName"));
> else
> out.println("New User");
> }%>
Change it to
<%
if(request.getParameter("usrName") != null) {
out.println(request.getParameter("usrName"));
} else {
out.println("New User");
}
%>
Yours
Johannes
[EMAIL PROTECTED] on 27.04.2000 09:40:27
Bitte antworten an [EMAIL PROTECTED]
An: [EMAIL PROTECTED]
Kopie: (Blindkopie: Johannes Akinlaja/nobisCum)
Thema: Re: out.println() stmt....
No not working..
> -----Original Message-----
> From: Ishwar Naik [SMTP:[EMAIL PROTECTED]]
> Sent: Thursday, April 27, 2000 12:14 PM
> To: [EMAIL PROTECTED]
> Subject: Re: out.println() stmt....
>
> hope this should work,
> <%
> if(request.getParameter("usrName") != null)
> out.println(request.getParameter("usrName"));
> else
> out.println("New User");
> %>
>
> naik
>
> -----Original Message-----
> From: Gogia Nitin [mailto:[EMAIL PROTECTED]]
> Sent: Thursday, April 27, 2000 11:48 AM
> To: [EMAIL PROTECTED]
> Subject: out.println() stmt....
>
>
> Can anyone tell me what's wrong with the code. I want to get the user
name
> from the FORM and display it on the screen. If the user name entered on
> the
> FORM is null i want to enter "New User".
> Now the problem is with 2nd part i.e. when User Name is null. "New User"
> is
> not being displayed on the screen and the JSP engine
> compiles the code correctly. So where exactly the problem lies ?
>
> <%if(request.getParameter("usrName") != null)
> {
> out.println(request.getParameter("usrName"));
> else
> out.println("New User");
> }%>
>
>
> Thanks in advance,
> Nitin
>
> =========================================================================
=
> =
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> 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".
> 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". 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".
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