Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp

preethi Ayyappan

Ranch Hand
+ Follow
since Oct 04, 2007
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by preethi Ayyappan

Hi ,

I am trying to validate a text field in Primefaces with # validations like
1. That field should have maximum of 99.99
2. That field should not allow alphabets
3. There should not be more than 2 digits after decimal point.

I have done the validation in regex . But I am unable to display the error messages according to the validation. I should display 3 error messages for the single text box validation. Please help me to do this using regex in annotation.

Thanks
6 years ago
Hi,

I am trying to read unread mail using pop3 server. But in pop3, as the unread mail is not read, i am taking the UID. But how can I get the mail for the particular UID?



Thanks
6 years ago
Hi,

I am using spring annotation and trying to pass data from jsp in springapp1 to springapp2. I have tried to pass the data using modelandview. But when i try to redirect to a jsp in another springapp, i am getting the following error


HTTP Status 404 - /springapp1/JSP/springapp2/jsp/indexdesign

type Status report

message /springapp1/JSP/springapp2/jsp/indexdesign

description The requested resource (/springapp1/JSP/springapp2/jsp/indexdesign) is not available.
Apache Tomcat/5.5.31


Please find the code below i have tried to pass data



Kindly assist to solve this issue.

Thanks
6 years ago
I have created two servlet application and tried the same. It is working fine. I think the issue is due to spring and i have to follow any other method which spring supports. Thanks for your help.
6 years ago
JSP
I have tried in tomcat7. but still facing the same issue. I am using spring annotation. It may be the reason?
6 years ago
JSP
I am using Tomcat 5.5. Is there any issue in using this version for cross context?
6 years ago
JSP
Thanks for your advise swastik. I have tried to pass through url query string and that is working. But the as the url displays the username and password data, i am trying for cross context method. But it is not working for me. I am using Tomcat server.

Is there any possibility to avoid displaying the datas passing in query string in the url?
6 years ago
JSP
I have tried the same. But i am still getting null. I have to change anything in web.xml?
6 years ago
JSP
please find the code i have used below:


I have to write it in init method? If yes, how do i redirect to the jsp in init method?
6 years ago
JSP
yes. I have restarted. Any other issue?
6 years ago
JSP
Thanks. I have included the following code in my servlet in webapp1


Then I have created a context.xml in META-INF in webapp1. The following is inside the context.xml file.


<Context path="/webapp2" docBase="/usr/local/apache-tomcat/webapps" crossContext="true" debug="0" reloadable="false" trusted="false" />



Then I have tried to get the value using servletcontext in my jsp in webapp2



But I am getting null pointer exception still in the line


ServletContext sc=getServletContext().getContext("/webapp2");



Please assist me
6 years ago
JSP
The context.xml file should be in both the webapplication?
6 years ago
JSP
Is the context.xml file under tomcat? or should we create a context.xml file in META-INF folder in the webapplication?
6 years ago
JSP
Hi,

I have used the context path <Context path="/webapp2" docBase="/home/web/webapp2'" crossContext="true" debug="0" reloadable="false" trusted="false" /> in the context.xml file of tomcat.

In webapp1, i have got the context using getcontext and forward the request to the jsp in webapp2 using request dispatcher.



But i am getting null pointer exception when trying to get the context. Am i going right? Kindly assist me to solve this issue.

Thanks
6 years ago
JSP
Should i give the context path in web.xml of both the web application?
6 years ago
JSP