Using TomCat to view JSP files
I've installed tomcat for the purpose of viewing jsp files.
In which folder am i supposed to place the jsp files to view them?
Also, what address am i supposed to type in my browser ( http://localhost:8080/myJspFile.jsp ?????? )
My tomcat folder is e:\tomcat
and JAVA_HOME is d:\jdk1.3
Thank you
Here is a good link for you to start from
http://www.moreservlets.com/Using-Tomcat-4.html#Try-Pages
http://localhost:8080/myJspFile.jsp
This looks right unless you have changed your port setting which the link above shows you how to change the port setting to port 80 so you dont have to type http://localhost:8080/blah it would http://localhost/blah.
You_tomcat_install/webapps/ROOT
or
You_tomcat_install/webapps/ROOT/some_dir
Anyways good luck and go to that link I gave you and it should help you out alot.
Similar Messages
-
How to use mxml in a jsp file?
I'm trying to use flex in a .jsp file. I followed the
suggestion that I use the Flex 2 Tag library as suggested by this
link:
http://labs.adobe.com/wiki/index.php/Flex_2_Tag_Library_for_JSP#Download_and_Installation
but I couldn't find it. I also downloaded LiveCycle Data Services
ES but couldn't find the flex-bootstrap.jar.
I have a simple example:
<!--<%@ taglib uri="FlexTagLib" prefix="mm" %>-->
Use the <mxml> tag to insert a Flex application in an
existing JSP page. The following example shows the <mxml> tag
with the source attribute to include an external MXML file:
<mm:mxml source="CustomerServiceChat.mxml"/>
Alternatively, you can use the <mxml> tag with inline
MXML source code, as the following example shows:
<mm:mxml>
<mx:Application xmlns:mx="
http://www.adobe.com/2006/mxml"
xmlns="*">
<mx:Text label="Hello World">
</mx:Application>
</mm:mxml>
I also added the following code in my web.xml:
<taglib>
<taglib-uri>FlexTagLib</taglib-uri>
<taglib-location>/WEB-INF/lib/flex-bootstrap.jar</taglib-location>
</taglib>
and obviously I get an error because I don't have the
flex-bootstrap.jar file. Please let me know how this can be
corrected. Thanks in advance!Adobe Newsbot hopes that the following resources helps you.
NewsBot is experimental and any feedback (reply to this post) on
its utility will be appreciated:
Adobe - Developer Center : Flex quick start guide for PHP
developers:
Apr 30, 2007 ... In this example, I changed the result data
type to XML with E4X support by setting .... In Flex you would
download a file using this code:
Link:
http://www.adobe.com/devnet/flex/articles/php_getstarted.html
2d. Tutorial - Flex 3 Getting Started - Adobe Learning
Resources:
See Calling XML Web Services over the Web Using the Web
Service References ... For information on integrating PHP and Flex
using AMF to encode the data,
Link:
http://learn.adobe.com/wiki/display/Flex/2d.+Tutorial
Mike Potter: Flex and PHP - A simple sample:
I have other example with PHP and MySql and give the same
error, and a example .... Flex Data Services... I choose None (???)
because I work with php and
Link:
http://blogs.adobe.com/mikepotter/2006/02/flex_and_php_a_1.html
Adobe - Developer Center : Transmitting data between Flex and
PHP:
Sep 4, 2007 ... Now that the user interface is set up and
ready to go you can add the HTTP services to go ask for the data
from the PHP code. In Flex you
Link:
http://www.adobe.com/devnet/flex/articles/flex_php_json.html
Integrating Adobe Flex and PHP:
Mar 1, 2006 ... The first step is to download Flex Builder
2.0 from the Adobe labs ... For example, you could use this same
PHP script to pass data to a
Link:
http://devzone.zend.com/article/11-Integrating-Adobe-Flex-and-PHP
Disclaimer: This response is generated automatically by the
Adobe NewsBot based on Adobe
Community
Engine. -
Use javabean object from jsp file
I try to use JDBC to open database, find my record and initiate and return a static object of javabean class. In my jsp file, I try to use this object, but it is null. My directory is C:/tomcat/webapps/myapp/web-inf/classes/bean. A "jsp" folder is under "myapp" directory. I put jsp file in "jsp" and bean class in "bean".
Is there some one can give me some suggestions?
thank you!
QiangI assume that the constructor for your object is inside the static method.
If the static method returns null, then the object is not being constructed.
There is nothing wrong with the JSP.
Thus the best place to look will be inside the static method. Use tracers like System.out.println() and printStackTrace() and I am sure u will find the problem.
One thing was not very clear to me. If u construct your object within the static method, there must be some reason for that. Since you are using parameters, this does not look like a singleton. Rather I think it is one object per input combinations you have provided. It is interesting as I have never seen this kind of code before(Except session EJB) It will be a nice learning experience if you post some documents regarding your design.
Shubhrajit -
Need help in using SQL in a jsp file to compare date and time
hi every one,
Actually I am doing a project using JSP. I need to compare a date field in the database (MS Acess) to the current system date and time. I have to do this in a select statement.
I have alredy defined a variable of type Date in the JSP file and I am comparing this variable to the date in the database through a select statemant.
Here is what I am doing
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-mm-dd hh:mm:ss");
java.util.Date today = new java.util.Date();
String myDate=sdf.format(today);
query = "SELECT Car_ID, Model_ID, Year, Ext_Color, Price from Cars where EDate <= "+myDate+" ;";
EDate is the feild in the database and it's format is (5/12/2008 5:29:47 PM) it is of type Date/Time in MS Acess.
when I execute the query it gives the following error
SQL error:java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'EDate <= 2008-10-16 08:10:07'.
I hope any one can help me with that error and answer my question, I've tried too many things but nothing helps
Thanks in advance :-)Hi,
When the comparision is needed to be done with the current date , we don't need to send in Java
Date then format it and compare with MS Acess Date.
In MS Access we have Date() function which will give you the current date.
So you can try rewriting your query as following :
query = "SELECT Car_ID, Model_ID, Year, Ext_Color, Price from Cars where EDate <= Date() ;"; ---------------------
Hope this helps.
Thanks -
Newbie - Error when trying to view .jsp file on newly running server.
Hello, I'm new and trying to view a .jsp file on my webserver and get this error:
java.io.IOException: CreateProcess: javac -d C:\Blazix\jspdir -classpath C:\Blazix\blazix.jar;C:\Blazix\classes; C:\Blazix\jspdir\desisoft_jsp_intro_jsp1152122045640.java error=2
*The .jsp file I want to view is in the correct folder, and I can view the same file if it is renamed as an .html extension. Plz Help!!! ThanksWhat does the JSP contain? Have you tried a simple JSP without any special functions? Does that work? How about catching the exception within the JSP. Will the JSP run and display correctly (of course, without the excepted content)?
Here is an example of how you can catch the exception and prevent the JSP from failing (or at least how to prod it to display despite the error):
<body>
<%
// yada yada yada some code
try{
// Yada yada yada the code that may have the IO problem
// Yada yada yada
}catch(IOException io){
System.err.println("Here is the exception: "+io.toString());
%>Please post back and let us know.
dailysun -
Using iMovie to view AVCHD files. Is this this only way?
Video clips taken from my JVC camera are in AVCHD fromat. I find it difficult and limited using iMovie to view, sort and send clips. I don't want to use iFrame as ther is a significant loss of quality even though iFrame is a much more manageable format for a Mac.
Can anyone tell me if there is a simple way of viewing and sorting AVCHD clips? Is ther some way they can be viewed the same way as iFrame from the finder menu?Mantas65 wrote:
... Is ther some way they can be viewed the same way as iFrame from the finder menu?
on your 'antique' system: No.
(G4 and 10.4 were invented way before AVCHD arised ... )
On any Intel-Mac/Mavericks (or higher), you just double-click in Finder, and get each clip as a preview... -
Using jikes to compile jsp files
Hello !
Where can i find a easy installation about jikes/WLS 6.0 sp6
to compile jsp files ?
Regards,
jsanza
just change the compile command for 6.x in weblogic.xml
kumar.
"jsanza" <[email protected]> wrote in message
news:3b814a50$[email protected]..
>
> Hello !
>
> Where can i find a easy installation about jikes/WLS 6.0 sp6
> to compile jsp files ?
>
> Regards,
>
> jsanza
>
-
Newbie trying to use tomcat to run jsp
I'm just trying to setup Tomcat on my machine, and i've run into a couple of issues.
(1) if i type in http://localhost:9000/test in IE, it gives me an error saying TCP_ERROR and how the web server is possibly down. however if i try it in Netscape, the page shows up fine. I read in the running.txt file that it had something to do with the LAN settings, but i have no idea what has to be done in there to get it to work??
(2) the second issue is, if i give someone the url http://<IP>:9000/test that is using another machine, what has to be done for them to see it? i had someone on another machine try it and they got page could not be found.
TIA>
(1) if i type in http://localhost:9000/test in IE, it
gives me an error saying TCP_ERROR and how the web
server is possibly down. Do you mean HTTP 500 error?
however if i try it in
Netscape, the page shows up fine. I read in the
running.txt file that it had something to do with the
LAN settings, but i have no idea what has to be done
in there to get it to work??
No LAN settings are needed. You're doing something else wrong. Is there a TOMCAT_HOME/webapps/test directory set up? Unless you created it, there's no such URL in Tomcat's setup.
(2) the second issue is, if i give someone the url
http://<IP>:9000/test that is using another machine,
what has to be done for them to see it? i had someone
on another machine try it and they got page could not
be found.
TIA If they can see the machine on the network, you don't have to do anything else special. If they can ping it, they can talk to Tomcat.
If you're a newbie, as your topic says, why are you changing things like the Tomcat port? Leave it as the default until you have Tomcat under your belt. - MOD -
I want to use preview to view pdf files without trashing the adobe plug-ins?
Some of the government web sites that I need to visit regularly require me to use firefox and adobe for opening and viewing files. I would like to still be able to use Safari and Preview for opening, viewing and printing files from other web sites. Before the latest adobe update this was no problem, but now Adobe seems to have taken control over the viewing and printing settings so that even though I try printing from a Safari viewer window I get an Adobe message that this is not supported. I tried to search for an answer as I suppose I am not the only one having this problem after the most recent Adobe update. Thanks for your great help everyone. /Christian
See if either of these help you.
https://support.mozilla.com/en-US/kb/Using+the+Adobe+Reader+plugin+with+Firefox
https://support.mozilla.com/en-US/kb/Opening+PDF+files+within+Firefox -
Can I use netui in Framework jsp files?
I'm trying to conditionally render an icon in the portlet titlebar.
I need to query the DB to determine which icon to display,
using a jpf action or method.
Can I use and access porlet obejcts in the framework skeleton files (titlebar.jsp) which is part of my theme?
zoyafDo you know how JSP can use a variable defined in Javascrip ?
Thx,
Lin
"Cameron Purdy" <[email protected]> wrote:
>Write your JSP as you would any HTML file, including JavaScript. Then
>rename the .html file to .jsp. Add your custom tags and Java code as
>desired. Done.
>
>There was a complaint in the 5.0 beta about the JSP parser choking on
>JavaScript, so I would make sure you at least try on the latest 5.1 service
>pack, just in case.
>
>Cameron Purdy
>
>"SRINIVAS" <[email protected]> wrote in message
>news:[email protected]..
>> Hai,
>> I know that we can use the jsvascript to validate the html parameters.
>>
>> Is the wblogic jsp support the javascript ?. I tried in weblogic
>> 5.1.0.,the javascript is not working.
>> anybody can help me how to validate html input and how can i use
>> javascript in jsp.
>>
>> Thanks
>> Srinivas
>>
>
>
-
How to use VBA to View PDF file and use an OCR object?
As subject, I need to use VBA to open PDFs via Acrobat. Convert images to texts. And get some key words from the documents.
But I cannot find the API for VBA from SDK.The API for VB is part of the "Interapplication Communication" section, specifically the part for "OLE". You can also use much of the JavaScript API through a VB:JavaScript linkage.
I don't know if there is an API to running OCR. -
How can I use a applet in a JSP file?
hi
I failed to use applet in a jsp file.My workspace is a BC4J type. I put the applet's source file in business component project.the jsp is in JSP project.
The jsp file calls applet by <jsp:plugin></jsp:plugin> style.
The error is can't find the applet class.
why? Thank someone for give me help.Actually using jsp applet tags does not mean that it is taking care of that the classes are available. It simply renders the Applet tag tothe JSP page. If e.g. teh codebase is specified as /java/, then there should be a mapping to the Java class location with thename of /java/. If codebase is not provided, then the Java class must be in the classpath of the JSp servlet.
Frank -
Passing parameters to included JSP files using JSF
I have included JSP, which I use in many other JSP files. I want to display message in this included JSP which depends on the information in JSP files which include this JSP. How can I do this without using scriptlets?
Message was edited by:
cheltsovI have one included page in one jsp page(mother page). I have included it by jsp:include tag. The included page consists of two inputText. I need to pass the parameters of the mother page together with the parameters in the included page in the backingBean of the mother page. Hope this one is clearer.
The code snippet in the mother page looks like this
<jsp:include page="/pages/ps/sample_rep2.jsp"/>.
In the sample_rep2.jsp, I have two inputText. How can I pass this in the backingBean of the motherpage.
The sample_rep2.jsp is the included page here. The sample_rep2.jsp looks like this:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://xmlns.oracle.com/adf/faces" prefix="af"%>
<af:panelBox>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://xmlns.oracle.com/adf/faces" prefix="af"%>
<af:panelBox>
<af:inputText label="User ID" id="userid" value="CDOUGLAS"/>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@ taglib uri="http://xmlns.oracle.com/adf/faces" prefix="af"%>
<af:panelBox>
<af:inputText label="User ID" id="userid" />
<af:inputText label="Age" id="age"/>
</af:panelBox> -
Problem in Using Java Bean in JSP
Hi,
I have a bean called BankAccount.....I tried to use it in a jsp file called Usebean.jsp like this <jsp:useBean id="BA" class="BankAccount" scope="application" /> I tried in both tomcat and j2ee1.3 server... but when i run the jsp file i get an error saying..... Class.org.apache.jsp.BankAccount not found...... But i have put the class file properly inse classes folder.....
Can anyone help me soon..... i am new to JSP........
Thanks,
AkshathaWell u need to have your class in a package
like mypackage.BankAccount
and put your class in classes/mypackage
<jsp:useBean id="BA" class="mypackage.BankAccount" scope="application" /> -
Where are the .java files compiled from .jsp files stored?
hi,
I'm new to weblogic server. When I use Tomcat as the jsp server, it compiles .jsp
files to .java files and then .class files. So when an error reported I can track
it in the .java file.
But what should I do with weblogic? It only saves the .class files in the work
dir. Or is there a better way to trace errors in jsp files?
Thanks!
This should give you the information you need to set the keepgenerated flag:
http://e-docs.bea.com/wls/docs60/jsp/admin.html#53346
Also, the .java files will be right next to the .class files with are under
a tmp directory in the /WEB-INF directory under the WEB-INF if it is an open
directory or in the
config/mydomain/applications/.wl_temp_do_note_delete/WEB-INF directory if it
is .war file.
Sam
"Raymond" <[email protected]> wrote in message
news:3b931619$[email protected]..
>
> Thanks, but can you tell me more about it? where to set this flag? I'm
using WLS
> 6.0sp1.
>
> "Sam Pullara" <[email protected]> wrote:
> >You can turn on the keepgenerated flag if you want to keep the .java
> >files.
> >How you do this depends on what version you are using.
> >
> >Sam
> >
Maybe you are looking for
-
HP Laserjet 6p printer stopped printing pdf files.
Using Windows xp pro and recently updated driver to postscript driver from HP web site (file name lj632en.exe) Have had problems printing large pdf files. Printer would take long time to start printing (maybe 10 mins) or fail to print error. This pri
-
How do I erase all my data securely before selling my IMac G5 computer
I will be selling my Imac G5 which was synced to my mobile me account. I know I can "unregister" the computer before selling but I want to make sure I securely erase my data for all the programs I have. I am selling the computer with Ilife and other
-
Pages 2 first impressions. A writers perspective.
Hi everyone, Well my copy of iWork 06 arrived today. Now bearing in mind that I am a fiction writer and the most I need from a word processor is the ability to display the Courier font, some spell checking and to do double line spacing, here are my i
-
Is Using Netbeans the best way to learn Java?
hi all. this is my first post. okay, I am total n00b. But I have been flirting with the idea of learning to code for about 2 years, and I think I need to leanr java, though I hear it is a difficult first language. but i love the platform independence
-
IPhoto 4 copied my library during install and now I have THOUSANDS of extra duplicates (iPhoto shows 6,341 photos...I don't have near that.) 1) Some are at a much lower resolution (240x180). 2) I have duplicates that took the original title and alter