jsp

Issue updating a dynamically-binded AutoPopulatingList in Spring/JSTL

Hello, I am having an issue updating a select box's value that was created from a dynamically-binded AutoPopulatingList. Here's what I have: An AutoPopulatingList "basicList" that contains "BasicDefinition" objects that I created. Each BasicDefinition object contains: String value OperatorType object (the OperatorType object contains...

JSP/Struts/JS form submission: how to modify inputted text data before submission?

Noob at javascript etc. here. I’m a php/core Java programmer tasked with maintaining a bunch of JS code in JSPs using Struts. What I need to do is simple, but I can’t figure out an easy solution. Given the following code excerpt for a struts’ed HTML form and a JS submit function, I need to modify the text field “query”’s data after the ...

JSP equivalent to the PHP include() function?

I just want to include an HTML file server-side into another HTML file, using JSP. PHP is not available. Is this what I want? <jsp:include page="/include.html"></jsp:include> ...

can sessions be periodically recycled depending on server load?

With servlets/jsp, can sessions be recycled by the web container (say tomcat), depending on how much traffic a site is getting? Update By recycled I mean, the tomcat container will wipe it out since it is running out of memory or busy trying to server requests for another website on the same server This happens with IIS and .net ...

Problem adding <listener> to web.xml in eclipse

Hi , I use Eclipse with Websphere server . I need to add a session listener . I added the class SessionListener.java in the package net.test . When I add the < listener > tag to the web.xml file , I get the folowing error : Distribution of configuration failed. See log for details. Error unmarshaling return; nested exception is: ...

jspx script element on GlassFish v3

The .war is served from GlassFish v3. I am trying to include a javascript file from my jspx. <script type="text/javascript" src="/base/interface/Service.js"></script> I get the following in my http response <script src="/base/interface/Service.js" type="text/javascript" /> The problem is that it should include the </script> tag. I...

specifying custom properties to a displaytag table decorator

I have a decorator specified on a displaytag table that I need to pass parameters to. The decorator adds an id attribute to the row. Currently the values I require are hardcoded. The parameters I need are: The name of the property to use as id value An id prefix (usually the property used is a number and IE doesn't like ids starting w...

Java Front Controller

Hi, I'm thinking of implementing Front Controller in my J2EE application. Could you please suggest the same with few links (with source code examples) & any standards to follow? Best regards ...

Setting up tomcat with eclipse on first jsp program

I am just following along the spring tutorial (http://static.springsource.org/docs/Spring-MVC-step-by-step/part1.html) I downloaded this version of Eclipse: http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/galileosr1 I guess tomcat is a separate install? Update Is Ant ready to go with eclipse, or that is yet an...

Where to put Java Simple Captcha Builder?

Hi, I am a newbie at java/java servlet. I need the simpleCaptcha for a form, using html and javaservlet for the code. With reference to http://simplecaptcha.sourceforge.net/extending.html. Captcha captcha = new Captcha.Builder(200, 50) .addText() .addBackground() .addNoise() .gimp() .addBorder() .build(); // Req...

Should mod_proxy_ajp or mod_jk be used for a production environment?

I've been searching over the past few days of whether I should use mod_proxy_ajp or mod_jk to connect apache httpd and tomcat. All the sites I find are a few years old and outdated. So, which is best to use for a proper production environment? Is mod_proxy_ajp mature enough to entirely replace mod_jk, or is mod_jk still best if you can ...

How can I put an active URL in a textbox?

Using JSP, how can I put an active URL in a textbox? ...

how to store value permanently in javascript variable

I want to make the application like below. First there is a page with four radio buttons. The user clicks on any of the radio buttons but doesn't save and he goes to another page. Then if he comes back to same page with the radio buttons it shows the selected radio button before he goes to another page. How can I do it by using jQuery,...

Problem in form validation with JavaScript

The editvalidate() function is not getting called at all: Please suggest why. What's the remedy? <script type="text/javascript"> function editvalidate() { var emailExp = /^[\w\-\.\+]+\@[a-zA-Z0-9\.\-]+\.[a-zA-z0-9]{2,4}$/; var numericExpression = /^[0-9]+$/; if(document.editprofile.userid.value == '' || document.editprofile...

How to generate unique string using jsp?

I need to verify the email. I want to do it by generating a unique string and making a link of it for users to click on it in the mail. I dont know how to generate it using Java. There are md5, sha1 etc functions in php to generate the string using any unique value like email. Is there same function provided in jsp? Advice please. ...

How to begin with Java Server Side technologies?

I have good knowledge of PHP. But I also want to learn technologies like JSP. I have installed Apache Tomcat 6.0 and Eclipse JEE. I was looking for JSP tutorials on Google and found that there are several things like JSP, Servlets, Struts, EJB, JSF, etc. I have heard a lot about Struts and JSF that they are very good. I want to know ...

Passing server-side objects from one JSP page to another

I know that I can use the getParameter() to pass client-side objects, but I am wondering what to use to pass server-side objects like I do with the getParameter. I have seen the getAttribute but do I need to use the setAttribute on the first JSP page and then the getAttribute on the second page. Any help would be greatly appriciated. ...

Eclipse ignoring source when deploying webapp

Hey, I'm running eclipse with tomcat 5.5. For some unknown reason from one day to the other eclipse stoped compiling my beans and java files that are in the source folder. If I go to the work directory, I find all the JSP compiled, the folders of the packadges i have, but no classes compiled inside of them. Neither eclipse, nor tomcat ...

how can i do sessions in java if some one disables cookies in my browser?

Hi, I like to know if someone disables the cookies in my browser then cookies dont work for my browser then how can I do sessions in java. I am writing servlets for server side programming. Then how does my sessions work? How does it recognize the user? As JSESSION ID is stored in cookies... ...

How to have unique keywords and description on each page of jsp/jsf ?

Our website skill-guru has dynamic contents. So we have lots of test and quiz and each page has this at top The keywords and description has to be unique for each test page. meta name="keywords" content="keyword 1 , keyword 2" meta name="description" content="The description goes here" How can we set this dynamically ? This is JSF ...