Running jsp program
Is it neccessary to install "Dream Weaver" to run JSP program while making a java bean program usin jsp and web login 8.
Dreamweaver is just another lousy drag'n'drop HTML page builder. It is not required in order to create/build/run JSP.
Look for Eclipse if you want an integrated development environment for Java/JSP.
Similar Messages
-
is i can able to run my jsp program by using appache server..
To get JSP working in Apache HTTP Server you have to install Apache Tomcat.
You can either choose to run JSP's solely on Apache Tomcat, or to use mod_jk2 to link Apache HTTP Server with Apache Tomcat so that the Apache HTTP Server can forward the JSP requests to the Apache Tomcat engine, because the Apache HTTP Server really doesn't know how to compile/run JSP's. -
I am not able to run JSP program
hi
I have done some jsp programs. i have installed tomcat 5. but when i tries to
execute jsp program it gives error as " Unable to get jstl ". it is not getting jasper-comppile.jar file.
Please any one can tell me how to specify path for jasper-compile.jar
thanking youSet the proper classpath.
http://jakarta.apache.org/tomcat/tomcat-5.0-doc/jasper-howto.html#Configuration -
Problem running JSP program on OAS 4.0.8.1 with JSP patch
Hi all
I've been running a JSP application on OAS 4.0.8.1 for a month now, but a week ago, when I updated a Java package on the server, the application will no longer run. The simple JSP pages with no bean-tags runs fine, but the ones with bean-tags doesn't work anymore.
This is the error message:
Request URI:/jsp/sag/login.jsp
Exception:
java.lang.VerifyError
at java.lang.ClassLoader.resolveClass(Compiled Code)
at oracle.jsp.app.JspClassLoader.loadClass(Compiled Code)
at java.lang.ClassLoader.loadClass(Compiled Code)
at oracle.jsp.app.JspAppLoader.instantiatePage(Compiled Code)
at oracle.jsp.app.JspAppLoader.reloadPage(Compiled Code)
at oracle.jsp.app.JspAppLoader.loadPage(Compiled Code)
at oracle.jsp.app.JspAppLoader.getPage(Compiled Code)
at oracle.jsp.app.JspApplication.dispatchRequest(Compiled Code)
at oracle.jsp.JspServlet.doDispatch(Compiled Code)
at oracle.jsp.JspServlet.service(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at oracle.OAS.servlet.servletrunner.exec(Compiled Code)
I've read on java.sun.com that verifyerrors normally is due to bad package-files, but I've rebuilt the package at least 10-times now, so thats probably not it. What could it be?
The application runs fine in JDeveloper 3.1
Thanks on advance,
Christian HolmHi,
I am trying to run JSPs on OAS 4.0.8.1.
I have installed JSP patch, downloaded form olab.com
I am not able to execute JSPs. I am getting 2 different problems.
1. If I call the JSP directly from browser, Netscape will ask for save option, it won't execute.
2. If I call the JSP from another page with submit button, I am getting the following error :
The requested access method is not allowed for that object.
Same error for any JSP.
The same problem for all the samples available with JSP patch.
Hi chrholm,
I already tested for 1 month, so
could you please help me to configure OAS 4.0.8.1 for JSPs.
Could you please send me mail : [email protected]
Any help appreciated.
Thanks,
Naidu
null -
How To Run JSP program On Tomcat
I have Installed Tomcat 6 and Jdk 6
and have following enviroment variable as written in readme
CATALINA_HOME = c:\apache
JAVA_HOME = C:\java\jdk1.6.0_04
JRE_HOME=C:\Program Files\Java\jre1.6.0_04
CLASSPATH = c:\java\jdk1.6.0_04\bin
PATH=C:\Java\jdk1.6.0_04\bin
the code is following
<%@page language="java" contentType="text/html"%>
<html>
<head><title>Hello World not-so-dynamic HTML</title></head>
<body>
Hello World!
</body>
</html> file name simple.jsp saved to C:\apache\webapps\ROOT
says 404 status
have tried index.html it works
so please tell me where's the problem
i think its in the enviroment variable
Thank for Reading
AND
Thanks A lot For helping (In advance)hi,
check your filename once..
simple.jsp
or
simple.JSP
check in url too. correctly mention or not.. -
Salam
How can i Compile & run JSP program?
SlamYou don't directly.
A JSP page runs on a java enabled webserver (eg Tomcat)
You need one of those to run JSP pages.
When you ask for a jsp page from the server, (eg http://localhost:8080/mySite/myjsp.jsp) the webserver translates and compiles it into a servlet and then runs it for you.
Cheers,
evnafets -
How to run BC4J JSP programs generated by JDeveloper 9i?
I used JDeveloper 9i to:
Create a new Project Workspace
Create New Business Components
Click on Run, Run Project
The Java application works perfectly alright.
Click on New, BC4J JSP, Business Components JSP Application
Then a full set of JSP source code is generated based on the Business Components Java Application.
Right-click on main.html, Run main.html
I can see that deployment of the JSP programs is OK but the Internet Explorer does not start the main.html.
I enter address: http://localhost:8988/ in Internet Explorer and can see that OC4J is running.
I would like to enter the path of the deployed JSP program.
How can I know what is the path of the URL?I have change the settings in tools->preferences to point to the right location, i.e.
C:\Program Files\Internet Explorer\IEXPLORE.EXE
Internet Explorer does not start after it shows:
C:\oracle\ora9ids\jdk\bin\javaw.exe -ojvm -classpath C:\oracle\ora9ids\j2ee\home\oc4j.jar -Dhttp.proxyHost=hqproxy.vtc.edu.hk -Dhttp.proxyPort=8080 com.evermind.server.OC4JServer -config C:\oracle\ora9ids\jdev\system\oc4j-config\server.xml
[Starting OC4J using the following ports: HTTP=8990, RMI=23893, JMS=9229.]
[waiting for the server to complete its initialization...]
Oracle9iAS (9.0.2.0.0) Containers for J2EE initialized
ApplicationServer: appName = bc4j
ApplicationServer: appName = current-workspace-app
ApplicationServer: appName = bc4j
ApplicationServer: appName = current-workspace-app
ApplicationServer: appName = bc4j
ApplicationServer: appName = current-workspace-app
ApplicationServer: appName = bc4j
ApplicationServer: appName = current-workspace-app
ApplicationServer: appName = bc4j
ApplicationServer: appName = current-workspace-app -
URGENT-CREATE A HTML FILE WITH AN STRING INPUT FROM THE RUNNING JSP
I am designing a web page where the user enters a page after entering his/her login and password.The User should now be provided with a display page containing the servers that he has permissions for access.The servers that he has permissions are maintained in a database(a normal text file in UNIX).
Till now the program has been complete for displaying the servers that are available to him.
I need to create a HTML form containing these servers names in a check box so that when the user clicks thcheck box against the server name it should go to the server and get the password for the required server.
THe intention from me is to create a HTML file that dynamically takes values from the running JSP means the server names as a string value to its input and then i can continue
Please guide me in creating a HTML form based on the string output from the running JSP
FileInputStream fs = new FileInputStream("/root/Auth_Application/User_Access_List");
DataInputStream in1 = new DataInputStream(fs);
int fl=0;
while (in1.available() !=0)
String str1=in1.readLine();
StringTokenizer st1 = new StringTokenizer(str1);
String usernam=st1.nextToken();
if (usernam.equals(uname))
String ip=st1.nextToken();
String host=st1.nextToken();
fl=1;
out.println("<tr><td> "+ host + "</td><td> " + ip +"</td></tr>");
if (fl == 0)
out.println("YOU HAVE NO SEVRER IN YOUR PROFILE !");
in1.close();
The host string here is the server name
the ip is the ip address of the server
Need to input these values to another HTML page that contains the check box list of the servers .
once these are clicked i think i can pass on this to another JSP and retreive passwords
Please guide me in thisFileInputStream fs = new FileInputStream("/root/Auth_Application/User_Access_List");
DataInputStream in1 = new DataInputStream(fs);
int fl=0;
while (in1.available() !=0)
String str1=in1.readLine();
StringTokenizer st1 = new StringTokenizer(str1);
String usernam=st1.nextToken();
if (usernam.equals(uname))
String ip=st1.nextToken();
String host=st1.nextToken();
fl=1;
out.println("<tr><td> "+ host + "</td><td> " + ip +"</td></tr>");
if (fl == 0)
out.println("YOU HAVE NO SERVER IN YOUR PROFILE !");
in1.close();I feel sorry for the inconvenience that is caused as i am new to using these forums.
I have here used a simple program to retreive the names of the servers that the users have acess to..
I have here read the servername and server ip stored from a file in UNIX in the running JSP.Now i need to pass these string variables to HTML file and display it in a Check box format.the strings host and ip have to be passed to the input of the HTML file so that they can further be processed once they are clicked using another JSP.
Can anybody please help me in Passing these strings from the running JSP and display it in a check box format -
What are the mistake in this JSP program?
Hi,all. I am a newcomer to learn JSP, and I sincerely hope somebody help me. the following is a JSP program, and I want it extract data from my database and show them on webpage as XML. But there always have some mistakes I cann't found it. Could somebody help me find out them and tell me how to correct. Thanks veeeeeeeeeeeery much!
<%@ page contentType = "text/xml" %>
<%@ page language="java" %>
<%@ page import = "java.sql.* " %>
<%@ page import = "java.io.* " %>
<%@ page import = "javax.xml.parsers.DocumentBuilder" %>
<%@ page import = "javax.xml.parsers.DocumentBuilderFactory" %>
<%@ page import = "org.w3c.dom.Document" %>
<%@ page import = "org.w3c.dom.Element" %>
<%@ page import = "org.w3c.dom.Node" %>
<%@ page import = "org.w3c.dom.NodeList" %>
<%@ page extends = "Object"%>
<html>
<head><title>Searching Page</title></head>
<body>
<p><INPUT size=22 name=T1></p>
<p><INPUT type=submit value=OK name=B3></p>
<% Document retailerDoc = null;
Document dataDoc = null;
Document newDoc = null;
try {
DocumentBuilderFactory dbfactory = DocumentBuilderFactory.newInstance();
DocumentBuilder docbuilder = dbfactory.newDocumentBuilder();
retailerDoc = docbuilder.parse("RetailerXmlExtract.xml");
//Instantiate a new Document object
dataDoc = docbuilder.newDocument();
//Instantiate the new Document
newDoc = docbuilder.newDocument();
}catch(Exception e){}
//Retrieve the root element
Element retailerRoot = retailerDoc.getDocumentElement();
//Retrieve the (only) data element and cast it to Element
Node dataNode = retailerRoot.getElementsByTagName("data").item(0);
Element dataElement = (Element)dataNode;
String driverName = "sun.jdbc.odbc.JdbcOdbcDriver";
String connectURL = "jdbc:odbc:Retailer";
Connection db = null;
try{
Class.forName(driverName);
db = DriverManager.getConnection(connectURL);
catch(ClassNotFoundException e){}
catch(SQLException e){}
//Create the PreparedStatement
PreparedStatement statement = null;
//Create the Resultset object, which ultimately holds the data retrieved
ResultSet resultset = null;
//Create the ResultSetMetaData object, which will holds
//information about the ResultSet
ResultSetMetaData resultmetadata = null;
//Create a new element called "data"
Element dataRoot = dataDoc.createElement("data");
try{
statement = db.prepareStatement("SELECT * FROM Orders");
//Execute the query to populate the ResultSet
resultset = statement.executeQuery();
//Get the ResultSet information
resultmetadata = resultset.getMetaData();
//Determine the number of columns in the ResultSet
int numCols = resultmetadata.getColumnCount();
//Check for data by moving the cursor to the first record(if there is one)
while(resultset.next()){
//For each row of data, create a new element called "row"
Element rowEl = dataDoc.createElement("row");
for(int i = 1; i <= numCols; i++){
//For each colum index, determine the column name
String colName = resultmetadata.getColumnName(i);
//Get the column value
String colVal = resultset.getString(i);
//Determine if the last column accessed was null
if(resultset.wasNull()){
colVal = "and up";
//Create a new element with the same name as the column
Element dataEl = dataDoc.createElement(colName);
//Add the data to the new element
dataEl.appendChild(dataDoc.createTextNode(colVal));
//Add the new element to the row
rowEl.appendChild(dataEl);
//Add the row to the root element
dataRoot.appendChild(rowEl);
catch(SQLException e){}
finally{
try{
db.close();
}catch(SQLException e){}
//Add the root element to the document
dataDoc.appendChild(dataRoot);
//Retrieve the root element (also called "root")
Element newRootInfo = (Element)retailerRoot.getElementsByTagName("root").item(0);
//Retrieve the root and row information
String newRootName = newRootInfo.getAttribute("name");
String newRowName = newRootInfo.getAttribute("rowName");
//Retrive information on element to be built in the new document
NodeList newNodesRetailer = retailerRoot.getElementsByTagName("element");
//Create the final root element with the name from the file
Element newRootElement = newDoc.createElement(newRootName);
//Retrieve all rows in the old document
NodeList oldRows = dataRoot.getElementsByTagName("row");
for(int i=0;i<oldRows.getLength();i++){
//Retrieve each row in turn
Element thisRow = (Element)oldRows.item(i);
//Create the ner row
Element newRow = newDoc.createElement(newRowName);
for(int j=0;j<newNodesRetailer.getLength();j++){
//For each mode in the new mapping, retrieve teh information
//First the new information........
Element thisElement = (Element)newNodesRetailer.item(j);
String newElementName = thisElement.getAttribute("name");
//Then the old information
Element oldElement = (Element)thisElement.getElementsByTagName("content").item(0);
String oldField = oldElement.getFirstChild().getNodeValue();
//Get the original values based on the mapping information
Element oldValueElement = (Element)thisRow.getElementsByTagName(oldField).item(0);
String oldValue = oldValueElement.getFirstChild().getNodeValue();
//Create the new element
Element newElement = newDoc.createElement(newElementName);
newElement.appendChild(newDoc.createTextNode(oldValue));
//Retrieve list of new elements
NodeList newAttributes = thisElement.getElementsByTagName("attribute");
for(int k = 0;k<newAttributes.getLength();k++){
//For each new attribute, get the order information
Element thisAttribute = (Element)newAttributes.item(k);
String oldAttributeField = thisAttribute.getFirstChild().getNodeValue();
String newAttributeName = thisAttribute.getAttribute("name");
//Get the original vale
oldValueElement = (Element)thisRow.getElementsByTagName(oldAttributeField).item(0);
String oldAttributeValue = oldValueElement.getFirstChild().getNodeValue();
//Create the new attribute
newElement.setAttribute(newAttributeName, oldAttributeValue);
//Add the new element to the new row
newRow.appendChild(newElement);
//Add the new row to the root
newRootElement.appendChild(newRow);
//Add the new root to the document
newDoc.appendChild(newRootElement);
try{
out.println("<?xml version=\"1.0\" encoding=\"UTF-8\"?>");
out.ptintln("<!DOCTYPE orders SYSTEM \"RetailerXml.dtd\">");
out.println(newRootElement.toString());
} catch(IOException e) {}
%>
</body>
</html>it reminded that there were some mistakes when i run this JSP program,so it must have something wrong, but due to my weak programming skills, I can not found these mistakes out. That must give me very useful help if you tell me how to solve them. thank you vrey much!
-
Help needed in executing the java/jsp program from UCM .
Hi ,
I have a .jsp program running in my Jdeveloper which when executed pops a window to browse and select files and with few custom options .
But i want to execute that Program from within UCM (create a new jsp page in UCM OR provide link ? i am not sure .... ) , could anyone help on how i can execute/run the program from UCM ?
thanks in Advance
PlaxmanIf your jsp makes use of jars you may want to look into using a WAR instead. You can check the WAR into content server and there is even a link on the administration page for JSP Web App Admin. Treating the JSP(s) and jar(s) as an entity may be a more successful path for you.
You can find some jsp examples and ever a war example in this directory: <install root>\samples\JspServer
And the briefest of help about that stuff here: [http://localhost/idc/help/wwhelp/wwhimpl/js/html/wwhelp.htm|http://localhost/idc/help/wwhelp/wwhimpl/js/html/wwhelp.htm] -
How to run servlet program in eclipse 3.1
i run the jsp program in eclipse 3.1
i want to run sample servlet program in eclipse, how to create the project,where to store the class file..? where to store the web.xml file..?
plz give explanation with HelloWorld.java program....Install WTP and follow the basic J2EE WebApp Tutorial from their WTP tutorials page.
-
How to setup my computer to run JSP and Servlets
I want to setup my computer to run JSP and Servlets.
What kind of Servers and other tool i need to install to run JSP and Servlets.
Plz, Help me to start my work on JSP.
Regards,
Usman Alihello
JSP and servlet is web programming, may be little bit different to development local application.
1st, you should have two computers: one is server and the other is local workstation. This server should have a static IP address, that other people can go into your server. Workstation is any computer normal you use it.
2nd, you need to setup your server in: OS(linux or windows 2000), web server (jrun, apach or Tomcat etc. ), as well as install JDK, servlet.
3rd, your local workstation just use as programming editor and open a browser to testing, anytime you write your code, then ftp to server to test.
Reality, you have many technical thing to solve, eg setup web server etc. However, you can write your source code and test it, then open to outside people.
hope to helpness, if anything don't uderstand, you can post again or send email to me [email protected] Since I just have setup this configuration in my university for my project. -
Hi frnds,
i am working on Jsp Tag Small example ..I wrote one JSP file,One .tld file and one .java files .That java file is compiled properly.While running that program i am getting error as below:
1..org.apache.jasper.JasperException: /Date.jsp(7,7) Unable to load tag handler class "tagexamples.PageVisitTag" for tag "test:pageVisit"
Here with i sent my File Structure and Source file also :
1.Date.jsp
<%@ page language="java" import ="java.util.Date" %>
<%@ page import="tagexamples.*" %>.
<html>
<title>Simple Date Tag</title>
<body>
<%@ taglib uri="/pageVisit.tld" prefix ="test" %>
<h2> <test:pageVisit /></h2>
<h2> Current System Date is <%= new Date().toString() %></h2>
</body>
</html>
2.pageVisit.tld
<?xml version="1.0" encoding ="ISO-8859-1" ?>
<!DOCTYPE taglib PUBLIC "=//Sun.Microsystems,Inc.//DTD Jsp Tag Library 1.1//EN"
"http://java.sun.com/j2ee/dtds/web-jsptaglibrary_1_1.dtd">
<taglib>
<tlibversion>1.0</tlibversion>
<jspversion>1.1</jspversion>
<shortname>date</shortname>
<info>
A simple tag Library for example
</info>
<tag>
<name>pageVisit</name>
<tagclass>tagexamples.PageVisitTag</tagclass>
<bodycontent>empty</bodycontent>
<info>
This tag Output the LastTime u have viisted the page in the Last MOnth..
This tag Ocntains empty Body and no attributes
</info>
</tag>
</taglib>
3.PageVisitTag.java
package tagexamples;
import javax.servlet.http.*;
import javax.servlet.jsp.*;
import javax.servlet.jsp.tagext.*;
import java.util.Date;
import java.io.IOException;
public class PageVisitTag extends TagSupport
public int doStartTag() throws JspTagException
Cookie info = null;
String msg = "This is the First time u have Visited this page" ;
//Get all Cookine s that Came from the Request
Cookie[] cookies = ((HttpServletRequest)pageContext.getRequest()).getCookies();
for (int i=0;i< cookies.length;i++)
info = cookies;
if(info.getName().equals("MyCookie"))
found = true;
break;
}//for
String newValue =""+System.currentTimeMillis();
if(!found)
//Create a new Cookie and set its age
info = new Cookie ("MyCookie",newValue);
info.setMaxAge(60*1);
info.setPath("/");
((HttpServletResponse)pageContext.getResponse()).addCookie(info);
}else {
long conv = new Long(info.getValue()).longValue();
msg = "U Last visited this site on "+new Date(conv);
//Set the new value of the Cookie and adddd it to the Response
info.setValue(newValue);
info.setMaxAge(10*24*60*60); //keep the cookie for One Month
//Set the Path so that the Cookie is available everywhere on the Server
info.setPath("/");
((HttpServletResponse)pageContext.getResponse()).addCookie(info);
} //else
try{
JspWriter out = pageContext.getOut();
out.write(msg);
}catch(IOException e){
throw new JspTagException("JspWriter not There :"+e);
return SKIP_BODY;
}//doStartTag ends
public int doEndTag() throws JspTagException {
if(!found){
//Don't Compare current and Cookie time this time
return SKIP_PAGE;
}else {
return EVAL_PAGE;
}//doEnd Tag ends
boolean found = false;
} //Class ends
while running the above files in Tomcat it giving above error:
i am running by:
http://localhost/TagExamples/Date.jsp
and
I kept files in the below Structre order.
My file Structure is :
D:\jakarta-tomcat-5.0.16\webapps\TagExamples\WEB-INF\classess\tagexamples\PageVisitTag.java
D:\jakarta-tomcat-5.0.16\webapps\TagExamples\Date.jsp
D:\jakarta-tomcat-5.0.16\webapps\TagExamples\pageVisit.tld
Just tell me is it Correct ..? and what is the Problem in COding and how to run a Tag Library
If anybody know the Solution just reply .send me the mail
[email protected]
with regards,
Ramesh P
98459 35822Do (dir if on windows, ls if on *nix) and you will probably see an A directory in the A directory. That came from your last compilation attempt. Remove it and everything in it. Now,
cd ..
javac A/Convertible.java
java A.Convertible -
I downloaded Tomcat and I installed. I set the JAVA_HOME and CATALINA_HOME variables to the appropriate values. I have the j2sdk1.4.1_01 installed. Although the http:localhost:8080/ is opening after that I do not know quite how I can run the examples.
I put a .jsp file in the webapps\ROOT and I tried to run it through IE with the URL
http://localhost/name.jsp as I read in a tutorial.
Is it wrong?It does not working anyway.
What can I do and how I can run jsp examples???
Please answer me...Do one thing put all your jsp files in a directory like my directory name is Jignesh, then it will be created in
C:\Program Files\Apache Tomcat 4.0\webapps\Jignesh
now to run any JSP file
you should write in address bar
http://localhost:8080/Jignesh/filename.jsp
and your tomcat must be running at that time. ok. hope this will help you. -
How to run jsp in weblogic server
hi,
how to run jsp application in weblogic server,plz send the procedure how to deploy..
ThanksHow to run JSP and EJB program using weblogic server
Maybe you are looking for
-
Trying to import IPhoto 6.06 into Aperture 3.0 But Import Button Disabled
I'm trying to import my iphoto 6.0.6 library into aperture 3.0. I was planning to leave the photos in place. I'm using file->import->iphoto library. Then I've entered store files in current location and do not import duplicates. The problem is that n
-
Active Directory - DS Name Cache rate hit thershold
Hi Team, I would like the information for DS Name Cache Rate Hit threshold limit. What is threshold limit so that I can understand there is some issues. Our monitoring systems is throwing alerts for DS Name Cache rate hit low its saying <80% on doma
-
Media browser has no photos in 4.3
Did the new Photos app break the media browser in Pages 4.3? I no longer see any photos, only Photo Booth is listed in the Photos tab. I tried rebooting my system, but nothing appears. Anyone else experiencing this?
-
Saving files in graphics formats
This question was posted in response to the following article: http://help.adobe.com/en_US/photoshop/cs/using/WSEC964A47-477C-4487-8CF4-332F92636117a.htm l
-
i have tried to download and update my photoshop creative cloud but to no avail im trying to get bridge but i push download and nothing happens, diane johnson