KTML for JSP Forum :: problem with functions in jsp

This thread was displayed: 828 times


Starting with 17th May 2007, Adobe Systems will stop offering support for any version of the discontinued InterAKT products. As a result, we will not answer to new support incidents starting with May 17th, 2007. Pending support incidents will still be followed in order to be closed. The product forums will remain open and be transformed in user-to-user forums. The general forums will be made read-only and not allow new posts or comments.

For more information about the affected products visit: www.interaktonline.com/Support/

View Threaded Show descending
sowjanya chakravarthi
07-10-2006 20:55:31 GMT +2

hear is my code

  <HTML>

<HEAD><TITLE>Hello</TITLE></HEAD>

<BODY>

<H1>

Hello, <%= getName(request) %>

</H1>

</BODY>

</HTML>

<SCRIPT RUNAT="server">

 String DEFAULT_NAME = "World";

String getName(HttpServletRequest req) {

String name = req.getParameter("name");

if (name == null)

return DEFAULT_NAME;

else

return name;

}

</SCRIPT>

 

i got this error

 

type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

org.apache.jasper.JasperException: Unable to compile class for JSP

 

An error occurred at line: 4 in the jsp file: /jsp/bobby/hello3.jsp

 

Generated servlet error:

    [javac] Compiling 1 source file

 

C:\Program Files\Apache Software Foundation\Tomcat 4.1\work\Standalone\localhost\examples\jsp\bobby\hello3_jsp.java:42: cannot find symbol

symbol  : method getName(javax.servlet.http.HttpServletRequest)

location: class org.apache.jsp.hello3_jsp

                                          out.print( getName(request) );

                                                     ^

1 error

 

 

        at org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:85)

        at org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:248)

        at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:343)

        at org.apache.jasper.compiler.Compiler.compile(Compiler.java:356)

        at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:427)

 

 

Back | Reply | Quote | Top
Ionut MOICIANU
07-11-2006 19:59:19 GMT +2

Hi,

Please explain how is this related to our KTML product.

Regards,
Ionut

Reply | Quote | Top
KTML for JSP 4.1.0
© Adobe Systems Romania. All rights reserved.