wood burning stoves 2.0*
The moose likes IDEs, Version Control and other tools and the fly likes Java class in JSP doubt Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "Java class in JSP doubt" Watch "Java class in JSP doubt" New topic
Author

Java class in JSP doubt

dhwani mathur
Ranch Hand

Joined: May 08, 2007
Posts: 621
hi all

i am trying to work in jsp's for that i am using
tomcat server and dreamweaver IDE
i have create a jsp now i want to call a

class like calculate.java which i have
designed in Eclipse IDE and use its static methods

till now i am executing my jsp on local host
in a web browser for that

i save my jsp
in webapps folder of tomcat 6.x which is in E:drive
in the E drive itself i have Eclipse also so now how can call my java
class in page tag of JSP in dreamweaver

<%@page import="java.util.Date,Business.calculate"%>?
what path i must specify here for calculate class?
or where i must save my java class?


Any help on above will be realy great thnx in advance

Dhwani:>Swimmers never weep.
Chetan Parekh
Ranch Hand

Joined: Sep 16, 2004
Posts: 3636
(1)Create CATALINA_HOME/webapp/YOUR_APP/WEB-INF/classes/Business folder. Copy calculate.class in to the folder. This should solve your problem.
(2)Avoid using multiple IDE. Use Eclipse for JSP and Class both. Attached any Tomcat Plug-in to Eclipse, it will make your life easier.


My blood is tested +ve for Java.
dhwani mathur
Ranch Hand

Joined: May 08, 2007
Posts: 621
Hi Chetan

Thanks for your help and advice i will try not to use many IDE's
but i dont have idea on

how to use Tomcat plug ins
with Eclipse can you ellaborate and explain a bit
also how to build JSP in eclipse?........?

it will be realy great...........
on more doubt you said me to create
CATALINA_HOME/webapp/YOUR_APP/WEB-INF/classes/Business folder
but i am i doubt where i must create this folder ?

in Tomcat 6.0
folder where i already have

Tomcat 6.0/work/catalina/localhost/org/apache/jsp.class files

any help on above will be grt
thnx in advance

Dhwani>Swimmers never weep.
P. Jain
Greenhorn

Joined: Jan 03, 2008
Posts: 15
You have to copy the jar file and put it in the plugins folder in the eclipse.

Go the place where you have installed eclipse and in eclipse you will find plugins folder put the jar in that folder.

Hope this solve your problem.

Follow Chetan's advice as it is good for you.


SCJP 5.0<br />SCWCD 5.0<br />Preparing for SCDJWS
dhwani mathur
Ranch Hand

Joined: May 08, 2007
Posts: 621
Hi thr

Thanks Prince Jain
i will try to do the same....!!!




Dhwani:>Swimmers never weep.
Raghavan Muthu
Ranch Hand

Joined: Apr 20, 2006
Posts: 3344

Originally posted by dhwani mathur:


how to use Tomcat plug ins
with Eclipse can you ellaborate and explain a bit
also how to build JSP in eclipse?........?



Here you go.. http://www.eclipsetotale.com/tomcatPlugin.html


CATALINA_HOME/webapp/YOUR_APP/WEB-INF/classes/Business folder
but i am i doubt where i must create this folder ?


CATALINA_HOME is an environment variable being set. It generally points to the folder/drive where you have installed Tomcat in the local machine.;

In tomcat, it will generally be TOMCAT_HOME as well. Just you need to check that out.


in Tomcat 6.0
folder where i already have

Tomcat 6.0/work/catalina/localhost/org/apache/jsp.class files


Whatever comes inside the "work" folder is created by Tomcat in the runtime and you should NOT depend on it. You may just check by editing the files in that location and as such it may help like a hot deployment.
[ January 07, 2008: Message edited by: Raghavan Muthu ]

Everything has got its own deadline including one's EGO!
[CodeBarn] [Java Concepts-easily] [Corey's articles] [SCJP-SUN] [Servlet Examples] [Java Beginners FAQ] [Sun-Java Tutorials] [Java Coding Guidelines]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Java class in JSP doubt
 
Similar Threads
good editor
a productive jsp/jboss/tomcat environment
oracle database and jsp
Simple examples of JSP
What�s your favourite Struts enabled JSP editor?