File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes Problem in JSP --help please Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "Problem in JSP --help please" Watch "Problem in JSP --help please" New topic

Problem in JSP --help please

kaarthik asokkumar

Joined: Jan 21, 2005
Posts: 29
I use Tomcat 5.0.
I created a servlet which will pass the result to a JSP page. I got an error saying that

**Unable to compile class for JSP is not on the classpath.
Perhaps JAVA_HOME does not point to the JDK.

but ive set the environment variable JAVA_HOME to javac. should i have to set java home in apache?? if yes where should i set in apache. THanks for ur help

SCJP 1.4, SCWCD 1.4,SCBCD 1.3.
sangeeta kapoor
Ranch Hand

Joined: Jun 15, 2004
Posts: 70
java_home needs to be set to ur jdk

kaarthik asokkumar

Joined: Jan 21, 2005
Posts: 29
thanks sangeetha but ive already set my java_home to my jdk its still not working

public void doPost(HttpServletRequest request,HttpServletResponse response) throws IOException,ServletException
String c=request.getParameter("color");

CoffeeExpert ce=new CoffeeExpert();
List result=ce.getbrands(c);


//1 **RequestDispatcherview=request.getRequestDispatcher("result.jsp");

Exception is thrown in line 1
kaarthik asokkumar

Joined: Jan 21, 2005
Posts: 29
Thanks for every one i finally fixed the probs. I had to reinstall the tomcat and then set the java home then to my jdk during my installation and worked
I agree. Here's the link:
subject: Problem in JSP --help please
jQuery in Action, 3rd edition