4,248 Topics
![]() | |
Say I have an image-generating website and every image is unique, and there is no way to know of the images beforehand, and each image has it's own page. On a button-click I would have to generate this unique (.JSP) file/page and then display the image in that one. e.g … | |
Am getting **java.lang.IndexOutOfBoundsException** while I try to uplaod a file to server. I checked the code at loaclhost and it was working fine, but after uploading it to the server am getting the error. **upload.jsp** <form action="UploadServlet" method="post" enctype="multipart/form-data"> <input type="file" name="select" value="" /> <input type="submit" value="Select Profile Pic" /> … | |
i have image on my web application. When i click that i will be redirected to track jsp.What that jsp does is track the image that is clicked and redirect to that image url .At present i asing response.sendredirect(URL) which will redirect in same window.Is there any possiblity to open … | |
I've had nighmares about this since 3 days ago and couldn't find anything by googling so here I am. As the title says so i need to find a way to store and then retrieve images from a mysql database I have tired the code below to do so (the … | |
hi, i managed to upload files from client to server hard disk using apache commons. how could iretrieve files to client from server again? plz gimme an idea of implementation thx beanboy. | |
I want to display image from database to my htnl form but it id not displayed. Image copied from database to local c:\file_upload folder but from this folder i want to display in img src in html form .project doesn't give any error but image not displayed on html form. … | |
hi, actualy i want to bring values from servlet to the dropdown of jsp. in my servlet i fetch the values from the database into the variable and now i want to list thosevalues in the dropdown of jsp page. please provide me the syntax for that. | |
Hello, need help from experts in jsp/servlet.. i have a program in jsp that needs to upload a file and save this in desired folder and send the filename to database.. and its working properly.. my problem is.. i dont know how to save the additional input text in database.. … | |
Hi all, I am in new in Advance Java. Can you suggest me good books or videos or any site to learn from scratch.and from where I have to start? Thanks in advance | |
<html> <body> <%@page import="java.sql.*"%> <form method="post" action="csea.jsp"> <table border="1"> <tr><th>Reg No</th><th>Name</th><th>Present/Absent</th></tr> <% String pa = request.getParameter("pa"); try { Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); Connection con = DriverManager.getConnection("jdbc:odbc:Student"); Statement st = con.createStatement(); ResultSet rs = st.executeQuery("select * from student_details"); while (rs.next()) { %> <tr><th><%=rs.getString("reg_no")%></th><th><%=rs.getString("s_name")%></th> <th><input type="text" name="pa"/></th> </tr> <% } st.executeUpdate("update csea set pa='"+pa+"'"); con.close(); … | |
Suppose i have a standalone java project that performs two main functions, send and recieve. I want to deploy it to the glassfish server to be used just like that. An EJB connects to it though a resource adapter, and i just want it to run one of those methods, … | |
Hi all, when I use equals method is not working when i tried to check password from database and from textfeild both the values are same but eqals method shows error my code is if(strPasswordNew.equals(passwordManager.getPassword())) My complete code for rreference String strPasswordOld=request.getParameter("oldpassword"); String strPasswordNew=(request.getParameter("newpassword")).trim(); String strPasswordNew1=(request.getParameter("newpassword1")).trim(); if(strPasswordNew.length()!=0 && strPasswordNew.equals(strPasswordNew1)){ dataManager.getConnection(); … | |
So i'm working on a java program that will eventually be used like a library on an EIS system. My next step is to work with the resource adapter, and i've never done anything like this before. I understand the architecture in this case and what the resource adapter does, … | |
I'm trying to create a jUnit test for my EJB's and if my app just contains a few beans everything's all good but as soon as I incorporate JPA and entity-classes my jUnit test blows up. My test fails at ejbContainer = javax.ejb.embeddable.EJBContainer.createEJBContainer(); and the stack trace says the following: … | |
is it possible not to include the account password for the user that will send the email. i tried not to put password but it does not work. the email that can send only is the one that is set. please help. this is the code: <%@ page import="java.io.*,java.util.*,javax.mail.*"%> <%@ … | |
the web app is a simple calculator that adds and subtracts. my problem is that the add and the subtract buttons don't work i get an error message: "An error occurred at line: 19 in the jsp file: /adder.jsp Invalid character constant" <% String name = (String) session.getAttribute("name"); if (name==null) … | |
package edu.edusys.demo.jdbc.dao; import java.sql.Connection; import java.sql.PreparedStatement; import java.sql.ResultSet; import java.sql.Statement; import java.util.ArrayList; import edu.edusys.demo.jdbc.bean.Customer; public class CustomerDAO { private Connection connection; public CustomerDAO(Connection connection) { super(); this.connection = connection; } public boolean addCustomer(Customer customer) throws Exception { String sql = "INSERT INTO Customer" + "(name,address,phone)" + "VALUES (?,?,?)"; PreparedStatement ps … | |
My web hosting service provider allows me to uplaod my ROOT.war file only. and there is no directory structure. So is there any way by which I can upload pics and add new pages or make changes in existing pages without re-uploading the entire ROOT.war file. P.S. I also want … | |
Hi,I havent posted in over a year but I need a good starting point for a class project. We are using netbeans with glassfish. We have to create online Library. Below is my starting point. Any help is appreciated.I just need a starting point at this time. Im a little … | |
![]() | I need help with this code. I get zero values, how can I stop generating numbers when I hit the target number? Thanks import java.awt.*; import java.awt.event.*; import javax.swing.*; import java.util.*; import java.util.concurrent.locks.ReentrantLock; /** * @author Marin */ public class TargetFinder extends JFrame { private static final long serialVersionUID = … ![]() |
Please any one help in this problem, stuck in this. i want difference of login time and log out time, get time from machine in this way 090010 (hour, minute,second), i want to separate time with "-" and insert in database. e.g. login time from machine = 091043 , save … | |
Hi everybody Please help me to configure Tomcat server. I was trying to do a lot of things also search a lot in internet for similar problems but can not find an answer. So I installed Tomcat and I belive it is running correctly: root@serg-PORTEGE-Z835:~/Downloads/apache-tomcat-6.0.35/bin# sh version.sh Using CATALINA_BASE: /home/serg/Downloads/apache-tomcat-6.0.35 … | |
hai am trying to submint form using document.forms.myForm.submit(). it's work fine in firefox.but it's not working in ie please help me.actual i have two from. I have also tried document.['myForm'].submit() method. <script type="text/javascript"> function showBrowser() { document.getElementById('imageFile').click(); } function submitElmentImage(){ document.forms.myForm.submit(); } </script> <html:form action="/ext" onsubmit="return validateElementForm(this)"> <html:button onclick="showBrowser()" /> … | |
the simple thing i want to achieve is to be able to browse a file on my system an then use a servlet to finally store the file as a byte stream to my DB2 database. Initially i started by using coding the servlet part as a java application by … | |
**Hello everyone, I dont know if im placing this in a good place. I have a problem with my application. Its a simple application with connecting to database, retriving info and populating table. I changed the apache tomcats context.xml to looks like this:** <Resource name="jdbc/test" auth="Container" type="javax.sql.DataSource" maxActive="100" maxIdle="30" maxWait="10000" … | |
Hi there i recently started web applications using jsp and servlets, is it possible to get all http sessions of logged in users in a servlet? | |
I need some help for the development of my website. I want to send and sms through jsp. anybody can help? i don't have any idea for this.. | |
hello every one i trying to display image in jsp by using following code <% System.out.println("from the view page"); String imagePath =(String) request.getAttribute("path"); System.out.println(imagePath); %> <img src="<%=imagePath %>"/> variable imagePath shows the correct path where imge is store but it doenot display any image please suggest me some way to … | |
Hello everyone, I am designing one website in which I want to build one chatting application. My problem is in which technology chat application will be develop like jsp, servlet and spring and how to start to develop chat application. I heard about RMI so using RMI it is possible … | |
m trying to connect my project wid oracle db ..wts wrong wid dis code yr....:( <%@page import="java.sql.ResultSet"%> <%@page contentType="text/html" pageEncoding="UTF-8"%> <%@ page import ="java.io.*"%> <%@ page import ="javax.servlet.*"%> <%@ page import ="javax.servlet.http.*"%> <%@ page import ="java.sql.*"%> <%@ page import="java.sql.*" %> <html> <head> <title>db</title> </head> <body> <% try{ System.out.println("hi"); Class.forName("oracle.jdbc.OracleDriver"); Connection … | |
HI, i want to store the text present in the text area in ms access database when user clicks submit button.....i am using macromedia dreamweaver..........pls kindly help me for doing this............ | |
Hello, I was looking for a way to post multipart/form data to a servlet using java standalone application. Any information would be helpful. | |
hello everybody first of all thanks to Daniweb and all its users for helping me lot of time. now come to the problem I've just started studying servlets 1 week back it was going well but i got one problrm when i try to run a packaged servlet code. path … | |
hi all, I have doubt in my project,I have created Login page using MVC, If user name and password correct then LoginServlet navigates **user.jsp** page which has has user name ,latest events,andd other user informations, In user.jsp i have one link for **editsettings.jsp** which helps to edit user details,after edit … | |
Hi Friends, I need to some help in connecting to webserver using c shell or tcl scripting in linux ie in my office in linux system we have some intranet which is run by tomcat server so i need to connect to that server and read some data existing in … | |
Hi, We are developing a software in j2ee/jboss appserver. I have designed a login page the source code of which is given below, loginpage.jsp <%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>index of third eye</title> <link rel="stylesheet" href="stylepage.css"> <meta http-equiv="Content-Type" content="text/html; … | |
Hello All, I am a newbie on this forum. My name is Krunal. I am a beginner of JAVA and JSP. I would like to learn more and more from this forum. Thank you in advance. :):) | |
Hello I appreciate all the help i can get on this ,i am running a javabean on my application server inside the network ,this java gets requests from the apache web server on the DMZ ,my firewall admin has rules for my users to connect using defined ports numbers ,my … | |
I have this Code... ifsDAO.java [CODE]package source; import java.sql.*; import java.sql.SQLException; import java.util.*; public class ifsDAO { private Database database; public ifsDAO(Database database) { this.database = database; } public List<ifsBean> list() throws SQLException { Connection connection = null; PreparedStatement statement = null; ResultSet resultSet = null; List<ifsBean> ifs_array = new … | |
Hi, I'm building a battleship game that has multiple sessions over an apache server. It's a server/client containing servlets & jsp's. Let's say i have a jsp page that shows all the boards, for each session i want this page to be refreshed as soon another player makes a move. … | |
Hi, I am having trouble debugging this code.Please be kind enough to have a look.[CODE]<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"> <title>Bogus Order Calculate</title> </head> <body> <H1>Bogus Order Calculate</H1> You ordered these items: <form action="FinalizeOrder.jsp" METHOD="POST"> <% if("Dictionary".equalsIgnoreCase(request.getParameter("book"))) { %><input type="hidden" name="book" value="10.00"> a Book<BR><% } if("Coffeecake".equalsIgnoreCase(request.getParameter("food"))) { %><input type="hidden" name="food" … | |
Hello, I am a beginner. I want to setup my local account in debug mode. My code is on the remote server. After setting up my local account in debug mode i want to use that code from a remote server . How should i do that? I am using … | |
I am writing a front end page on jboss 4.2 and in my main page there are some redirection links to other pages. Somehow, when a user clicks on a link the redirected page address is shown with IP. tag's src attribute is "./newPage.jsp" Can you help me please, am … | |
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Integration of TC and P6</title> <meta http-equiv="pragma" content="no-cache"> <meta http-equiv="cache-control" content="no-cache"> <meta http-equiv="expires" content="0"> <title>User</title> <script type="text/javascript"> </script> <link type="text/css" rel="stylesheet" href="../css/style.css" media="all" /> <CENTER> <h1>Primavera-Teamcenter Integration</h1> </CENTER> </head> … | |
Hello, I'm doing a simple J2EE application that will interact with a database like Oracle and you know that a database can have multiple oracle schemas and that is the problem (because I do not know how to configure hibernat with multiple schemas :( because my application can handle multiple … | |
Can anyone tell me which book i have to preferred for java servlets.If any one has program with him then please post them. | |
I can't upload file with form data. I am getting null value when accessing Request.getParameter("name"); how can i upload file as well as form data please help | |
Hi, I have developed a web application using NetBeans and GlassFish v3. Now I want to change to Apache Tomcat, beacause of the unavalabilty of free GlassFish web hosting. So, my question is that, can I change my fully built web application to Apache Tomcat from GlassFish and [B]If yes … | |
Hi at all. I'm a new user of jsp and I've a problem. I would execute certain operations every X seconds in my jsp project like check data into mySql DB; I use a TimerTask java class and it's ok. But if I would update the UI inside the run … | |
The datafile which we need to upload to tables in our project, is an external ".CSV" file which has text in the following format (This is just 1/20 th part of it..the remaining has more sets as these, nearly 20 sets of such data with different values) @110516060031<M02m00-7959=+35.69,+35.69,+35.68,+35.68,+35.69,+35.69,+35.71,+35.71,+35.71,+35.71,+35.69,+35.69,+35.68,+35.68,+35.69,+35.69,+35.72,+35.72,+35.76,+35.76,+35.80,+35.80,+35.83,+35.83,+35.86,+35.86,+35.86,+35.86,+35.86,+35.86,+35.87,+35.87,+35.87,+35.87,+35.83,+35.83,+35.80,+35.80,+35.76,+35.76,+35.75,+35.75,+35.76,+35.76,+35.75,+35.75,+35.73,+35.73,+35.73,+35.73,+35.76,+35.76,+35.75,+35.75,+35.73,+35.73,+35.69,+35.69,+35.68,+35.68,+35.66,+35.66,+35.66,+35.66,+35.62,+35.62,+35.61,+35.61,+35.58,+35.58,+35.54,+35.54,+35.53,+35.53,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.53,+35.53,+35.53,+35.53,+35.53,+35.53,+35.51,+35.51,+35.51,+35.51,+35.51,+35.51,+35.54,+35.54,+35.53,+35.53,+35.55,+35.55,+35.59,+35.59,+35.59,+35.59,+35.59,+35.59,+35.62,+35.62,+35.64,+35.64,+35.64,+35.64,+35.66,+35.66,+35.66,+35.66>172xxxxxxxxxxxx @110516060032<M02m02-7959=+35.30,+35.30,+35.30,+35.30,+35.33,+35.33,+35.34,+35.34,+35.37,+35.37,+35.37,+35.37,+35.37,+35.37,+35.40,+35.40,+35.39,+35.39,+35.41,+35.41,+35.41,+35.41,+35.39,+35.39,+35.34,+35.34,+35.32,+35.32,+35.29,+35.29,+35.26,+35.26,+35.23,+35.23,+35.22,+35.22,+35.21,+35.21,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.19,+35.18,+35.18,+35.19,+35.19,+35.18,+35.18,+35.18,+35.18,+35.18,+35.18,+35.18,+35.18,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.18,+35.18,+35.18,+35.18,+35.16,+35.16,+35.18,+35.18,+35.18,+35.18,+35.16,+35.16,+35.18,+35.18,+35.18,+35.18,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.18,+35.18,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.16,+35.18,+35.18,+35.16,+35.16,+35.18,+35.18,+35.19,+35.19,+35.21,+35.21,+35.22,+35.22,+35.23,+35.23,+35.25,+35.25>074xxxxxxxxxxxx @110516060033<M02m04-7959=+35.47,+35.47,+35.47,+35.47,+35.43,+35.43,+35.48,+35.48,+35.40,+35.40,+35.44,+35.44,+35.51,+35.51,+35.47,+35.47,+35.44,+35.44,+35.44,+35.44,+35.51,+35.51,+35.48,+35.48,+35.44,+35.44,+35.51,+35.51,+35.46,+35.46,+35.46,+35.46,+35.46,+35.46,+35.48,+35.48,+35.48,+35.48,+35.44,+35.44,+35.48,+35.48,+35.41,+35.41,+35.41,+35.41,+35.48,+35.48,+35.47,+35.47,+35.44,+35.44,+35.39,+35.39,+35.46,+35.46,+35.44,+35.44,+35.40,+35.40,+35.44,+35.44,+35.37,+35.37,+35.40,+35.40,+35.39,+35.39,+35.41,+35.41,+35.41,+35.41,+35.37,+35.37,+35.43,+35.43,+35.36,+35.36,+35.37,+35.37,+35.41,+35.41,+35.41,+35.41,+35.39,+35.39,+35.34,+35.34,+35.43,+35.43,+35.41,+35.41,+35.39,+35.39,+35.44,+35.44,+35.37,+35.37,+35.37,+35.37,+35.37,+35.37,+35.43,+35.43,+35.44,+35.44,+35.40,+35.40,+35.44,+35.44,+35.40,+35.40,+35.41,+35.41,+35.47,+35.47,+35.46,+35.46,+35.44,+35.44>162xxxxxxxxxxxx … |
The End.