I have questions about import java class in JSP,like follow structure

test
 |
 |__WEB-INF
      |
      |__classes

In classes directory,I put a java class named hello.class,and I put a JSP file in test 
directory,named index.jsp ,and In index.jsp called hello class,but I don't use 
"import",I think JSP can find it.
/*hello.java*/
public class hello{
    String a;
    public hello(String a){
       this.a=a;
    }
    public String getValue(
       return a;
    }
}

But when I run index.jsp,it raised error:
    cannot resolve symbol : class hello
Then I copy hello class into test directory,it still raise above errors.

My questions are:
1.I want to know what default path which JSP use class
2.I don't want to use "package" in hello.java, If I use import in JSP,how to write 
this import statement?

Thanks.



===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
For digest: mailto [EMAIL PROTECTED] with body: "set JSP-INTEREST DIGEST".

Some relevant archives, FAQs and Forums on JSPs can be found at:

 http://java.sun.com/products/jsp
 http://archives.java.sun.com/jsp-interest.html
 http://forums.java.sun.com
 http://www.jspinsider.com

Reply via email to