Fw: Validator framework introduces errors

2005-11-12 Thread Martin Gainty
I did'nt see the (StudentEnquiry.jsp) jsp page which references centreList 
bean?

I also dont see the code for centreList bean?

Martin-

- Original Message - 
From: Raghu Kanchustambham [EMAIL PROTECTED]

To: Struts Users Mailing List user@struts.apache.org
Sent: Saturday, November 12, 2005 9:40 AM
Subject: Validator framework introduces errors


Hi,
The minute I introduced Validator framework in my application .
it started giving me the following error when I accessed the JSP 
centreList is used as a parameter for the dropdown. The minute I remove the
validation.xml from the path... the application runs fine again! :(
very strange and i am not able to explain this behavior .. can someone
help?
 Thanks much in advance.
Regards,
Raghu

javax.servlet.jsp.JspException: Cannot find bean centreList in any scope
org.apache.struts.util.RequestUtils.lookup(RequestUtils.java:938)
fr.improve.struts.taglib.layout.field.OptionsCollectionTag.doStartTag(OptionsCollectionTag.java:115)
org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_optionsCollection_0(StudentEnquiry_jsp.java:1088)
org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_select_2(StudentEnquiry_jsp.java:1062)
org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_grid_1(StudentEnquiry_jsp.java:1028)
org.apache.jsp.student.StudentEnquiry_jsp._jspService(StudentEnquiry_jsp.java:258)





My validation.xml (very simple one):

!DOCTYPE form-validation PUBLIC
 -//Apache Software Foundation//DTD Commons Validator Rules
Configuration 1.0//EN
 http://jakarta.apache.org/commons/dtds/validator_1_0.dtd;


form-validation
   formset
   form name=studentEnquiryForm
   field  property=studentEnquiry.firstName depends=required
   arg0 key=firstName.mandatory/
   /field
   /form
   /formset
/form-validation

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Fw: Validator framework introduces errors

2005-11-12 Thread Raghu Kanchustambham
Hi Martin,
 I do something like:
 request.setAttribute(centreList,DataAccessManager.getCentres());
 before invoking the jsp.
 The strange part is, the minute i remove validation.xml from the validator
path, effectively removing the validation framework, every thing works just
fine! Just cant explain it ! :(
 Thanks again in advance to anyone who can explain this!
  Please find the StudentEnquiry.jsp attached.


%@ page import=
com.tuningfork.student.businessobject.enquiry.StudentEducationDetail%
%@ page language=java %
%@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean %
%@ taglib uri=/WEB-INF/struts-html.tld prefix=html %
%@ taglib uri=/WEB-INF/struts-logic.tld prefix=logic %
%@ taglib uri=/WEB-INF/c.tld prefix=c %
%@ taglib uri=/WEB-INF/struts-layout.tld prefix=layout %

layout:html
head
titleStudent Enquiry/title

link rel=stylesheet type=text/css href=../mystyle.css /
SCRIPTfunction set(target) {document.forms
[0].operation.value=target;}/SCRIPT
/head
body
h2Student Enquiry/h2
html:errors/
c:set var=operationVar
%= request.getParameter(nextOperation)%
/c:set

c:set var=readOnlyForm false /c:set

c:if test=${operationVar=='null' || operationVar=='ok'} !-- view doesnt
have a Next operation --
c:set var=readOnlyForm true /c:set
/c:if
html:form action=StudentEnquiry.do
onsubmit=validateStudentEnquiryForm(this);
input type=hidden name=operation
value=%=request.getParameter(nextOperation)%
/
table width=100%
tr
td rowspan=2
[EMAIL PROTECTED] file=StudentDemographics.jsp%
/td
td
layout:grid cols=2
layout:select property=enquiryCentreId size=${selectBoxSize}
key=Enquiry Centre
layout:options collection =centreList property=id labelName=name /
/layout:select
layout:select property=enquiryCourseId size=${selectBoxSize}
key=Enquiry Course
layout:optionsCollection name=courseList value=id label=name/
/layout:select
/layout:grid

/td
/tr


tr
td
/td
td align=center
html:submit${operationVar} /html:submit
html:cancelcancel/html:cancel
/td
/tr

/table


/html:form

/body
/layout:html



 On 11/12/05, Martin Gainty [EMAIL PROTECTED] wrote:

 I did'nt see the (StudentEnquiry.jsp) jsp page which references centreList
 bean?
 I also dont see the code for centreList bean?

 Martin-

 - Original Message -
 From: Raghu Kanchustambham [EMAIL PROTECTED]
 To: Struts Users Mailing List user@struts.apache.org
 Sent: Saturday, November 12, 2005 9:40 AM
 Subject: Validator framework introduces errors


 Hi,
 The minute I introduced Validator framework in my application .
 it started giving me the following error when I accessed the JSP 
 centreList is used as a parameter for the dropdown. The minute I remove
 the
 validation.xml from the path... the application runs fine again! :(
 very strange and i am not able to explain this behavior .. can someone
 help?
 Thanks much in advance.
 Regards,
 Raghu

 javax.servlet.jsp.JspException: Cannot find bean centreList in any scope
 org.apache.struts.util.RequestUtils.lookup(RequestUtils.java:938)
 fr.improve.struts.taglib.layout.field.OptionsCollectionTag.doStartTag(
 OptionsCollectionTag.java:115)

 org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_optionsCollection_0
 (StudentEnquiry_jsp.java:1088)
 org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_select_2
 (StudentEnquiry_jsp.java:1062)
 org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_grid_1
 (StudentEnquiry_jsp.java:1028)
 org.apache.jsp.student.StudentEnquiry_jsp._jspService
 (StudentEnquiry_jsp.java:258)





 My validation.xml (very simple one):

 !DOCTYPE form-validation PUBLIC
 -//Apache Software Foundation//DTD Commons Validator Rules
 Configuration 1.0//EN
 http://jakarta.apache.org/commons/dtds/validator_1_0.dtd;


 form-validation
 formset
 form name=studentEnquiryForm
 field property=studentEnquiry.firstName depends=required
 arg0 key=firstName.mandatory/
 /field
 /form
 /formset
 /form-validation



Re: Fw: Validator framework introduces errors

2005-11-12 Thread Martin Gainty

I didnt see the contents E.G. tag /tag for your c.tld ??
Martin-
- Original Message - 
From: Raghu Kanchustambham [EMAIL PROTECTED]

To: Struts Users Mailing List user@struts.apache.org
Sent: Saturday, November 12, 2005 10:37 AM
Subject: Re: Fw: Validator framework introduces errors


Hi Martin,
I do something like:
request.setAttribute(centreList,DataAccessManager.getCentres());
before invoking the jsp.
The strange part is, the minute i remove validation.xml from the validator
path, effectively removing the validation framework, every thing works just
fine! Just cant explain it ! :(
Thanks again in advance to anyone who can explain this!
 Please find the StudentEnquiry.jsp attached.


%@ page import=
com.tuningfork.student.businessobject.enquiry.StudentEducationDetail%
%@ page language=java %
%@ taglib uri=/WEB-INF/struts-bean.tld prefix=bean %
%@ taglib uri=/WEB-INF/struts-html.tld prefix=html %
%@ taglib uri=/WEB-INF/struts-logic.tld prefix=logic %
%@ taglib uri=/WEB-INF/c.tld prefix=c %
%@ taglib uri=/WEB-INF/struts-layout.tld prefix=layout %

layout:html
head
titleStudent Enquiry/title

link rel=stylesheet type=text/css href=../mystyle.css /
SCRIPTfunction set(target) {document.forms
[0].operation.value=target;}/SCRIPT
/head
body
h2Student Enquiry/h2
html:errors/
c:set var=operationVar
%= request.getParameter(nextOperation)%
/c:set

c:set var=readOnlyForm false /c:set

c:if test=${operationVar=='null' || operationVar=='ok'} !-- view doesnt
have a Next operation --
c:set var=readOnlyForm true /c:set
/c:if
html:form action=StudentEnquiry.do
onsubmit=validateStudentEnquiryForm(this);
input type=hidden name=operation
value=%=request.getParameter(nextOperation)%
/
table width=100%
tr
td rowspan=2
[EMAIL PROTECTED] file=StudentDemographics.jsp%
/td
td
layout:grid cols=2
layout:select property=enquiryCentreId size=${selectBoxSize}
key=Enquiry Centre
layout:options collection =centreList property=id labelName=name /
/layout:select
layout:select property=enquiryCourseId size=${selectBoxSize}
key=Enquiry Course
layout:optionsCollection name=courseList value=id label=name/
/layout:select
/layout:grid

/td
/tr


tr
td
/td
td align=center
html:submit${operationVar} /html:submit
html:cancelcancel/html:cancel
/td
/tr

/table


/html:form

/body
/layout:html



On 11/12/05, Martin Gainty [EMAIL PROTECTED] wrote:


I did'nt see the (StudentEnquiry.jsp) jsp page which references centreList
bean?
I also dont see the code for centreList bean?

Martin-

- Original Message -
From: Raghu Kanchustambham [EMAIL PROTECTED]
To: Struts Users Mailing List user@struts.apache.org
Sent: Saturday, November 12, 2005 9:40 AM
Subject: Validator framework introduces errors


Hi,
The minute I introduced Validator framework in my application .
it started giving me the following error when I accessed the JSP 
centreList is used as a parameter for the dropdown. The minute I remove
the
validation.xml from the path... the application runs fine again! :(
very strange and i am not able to explain this behavior .. can someone
help?
Thanks much in advance.
Regards,
Raghu

javax.servlet.jsp.JspException: Cannot find bean centreList in any scope
org.apache.struts.util.RequestUtils.lookup(RequestUtils.java:938)
fr.improve.struts.taglib.layout.field.OptionsCollectionTag.doStartTag(
OptionsCollectionTag.java:115)

org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_optionsCollection_0
(StudentEnquiry_jsp.java:1088)
org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_select_2
(StudentEnquiry_jsp.java:1062)
org.apache.jsp.student.StudentEnquiry_jsp._jspx_meth_layout_grid_1
(StudentEnquiry_jsp.java:1028)
org.apache.jsp.student.StudentEnquiry_jsp._jspService
(StudentEnquiry_jsp.java:258)





My validation.xml (very simple one):

!DOCTYPE form-validation PUBLIC
-//Apache Software Foundation//DTD Commons Validator Rules
Configuration 1.0//EN
http://jakarta.apache.org/commons/dtds/validator_1_0.dtd;


form-validation
formset
form name=studentEnquiryForm
field property=studentEnquiry.firstName depends=required
arg0 key=firstName.mandatory/
/field
/form
/formset
/form-validation



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]