HI David,
I will explain what I meant.
SavePlanProfileAction.java is a action class and not actionform.
In the JSP I am using a hidden text field html:hidden
property=regularPlan value=true/
Now I am submitting this JSP to SavePlanProfileAction.java.
In the SavePlanProfileAction.java action
Hi,
How do I validate if a field is entered or not using the DynaActionForm?
My HTML form has html:text/ and html:radio/ buttons. I want to check if
the user has entered some text in the text field and that he has selected
the radio button.
If he has not selected, then show him a error message
If I have defined
c:set var=index value=0/
in a JSP, and I have saved an ActionMessage keyed on 'quantity.0' into the
Request, during execution of my Action,
should I expect either or both of
html:errors property=quantity.${index}/
html:errors property=quantity.c:out value='${index}'//
to
Hmm, you did not say in the original email - are you using the html-el tld?
If not, it will not work.
Larry
On Sat, 8 Jan 2005 22:16:49 +1000, William Ferguson
[EMAIL PROTECTED] wrote:
If I have defined
c:set var=index value=0/
in a JSP, and I have saved an ActionMessage keyed on
Well,
thats the thing, with Struts 1.2.4 (I quoted the wrong version before), I
could only find the standard TLDs.
Ie there weren't standard and el versions.
However the versions that were supplied appear to suppport runtime
expressions.
Here is the definition for html:errors:
tag
Is this tomcat 5?
On Sat, 8 Jan 2005 23:11:43 +1000, William Ferguson
[EMAIL PROTECTED] wrote:
Well,
thats the thing, with Struts 1.2.4 (I quoted the wrong version before), I
could only find the standard TLDs.
Ie there weren't standard and el versions.
However the versions that were
Yes. Tomact 5.0.28
Is that significant?
William
- Original Message -
From: Larry Meadors [EMAIL PROTECTED]
To: William Ferguson [EMAIL PROTECTED]
Cc: Struts Users Mailing List user@struts.apache.org
Sent: Saturday, January 08, 2005 11:39 PM
Subject: Re: Runtime expressions
Is this
On Sat, 8 Jan 2005 22:16:49 +1000, William Ferguson
[EMAIL PROTECTED] wrote:
html:errors property=quantity.${index}/
html:errors property=quantity.c:out value='${index}'//
You can't nest any custom tags like this.
Following works well with JSP 1.2:
html-el:errors
If the hidden field is not part of the form, then you don't want to use the
html:hidden tag in your JSP page, you want to use the plain input
type=hidden name=regularPlan value=xxx/ and then use
request.getParameter(regularPlan in your Action class to get it.
-Richard
At 10:57 PM 1/6/2005, you
(This is my last comment on this thread)
Like Richard said, if the hidden field is not part of that particular form
you'll see an error/exception. The syntax I'd recommended was to insert a
hidden field IF the data you want to display (that regularPlan field) is
from another stored Form (such as
I have an LogonForm, LogonAction and when a user successfully logs on, I set
Attributes for userID and userName.
How would be the best way to make this information available to the Web App
regardless of whether I need the data from within a JSP, servlet or class
file(for example, building a
One (rather pointed) question: Being that RequestProcessor is one of
the primary extension points for the Action servlet, how will this
new API affect HTTPS protocol handling? I assume that the SSLExt
library will have to be completely rewritten, or are you guys
planning on rolling that
This looks like you are asking some JDBC questions about some specific
database, Jim. Sorry to say this if you are not. If so, let me just
get you going partly by saying that you probably want to use a
PreparedStatement rather than a Statement. Start there? Have you
read up on JDBC?
Jack
On
I was ready to reply about three hours ago, but I had a feeling my
answer was way too simplistic... Reading the question again, I'm not so
sure...
As long as you only ever need these attributes in the context of a
request (and that's the case for a JSP or a servlet), just store them in
Maybe we can break this down quick and avoid a long thread.
snip
I have an LogonForm, LogonAction and when a user successfully logs on, I set
Attributes for userID and userName.
/snip
We don't know (A) where userID and userName come from or (B) why
you set them as attributes in the session.
Maybe it's simple, like I thought it might be, maybe it's not. I gave
him the simple answer, you gave him a not-so-simple answer. Maybe we
helped, maybe we didn't, he'll have to come back with more details if not.
--
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
To access DB in Struts (and elsewhere) there is a Wiki page:
http://wiki.apache.org/struts/DaoRelated
So... anyone that wants to help people w/DAO can add to it.
.V
Jim Douglas wrote:
I have an LogonForm, LogonAction and when a user successfully logs on,
I set Attributes for userID and userName.
... as I seem to get stuck on the simplest things.
For example:
I have set up Eclipse with MyEclipse (thanks, Jim Barrows, for this
recommendation)
and just trying to get simple page flow working. But I don't seem to
understand 'forwards',
as I have a 2-line index.jsp:
%@ taglib
Sorry Jim, I have to agree with the other posters...this is a really
unclear question.
I think what you are asking is this: When a user logs in, i want to
put the user id and password somewhere that i can always find it
easily.
If so, put it in session scope. It will be there until the session
Krisha,
To recap your issue:
JSP html:hidden property=regularPlan value=true / --
SavePlanProfileAction.java
[request.getParameter(regularPlan);] ---
/acctmgmt/updatePlanProfileContent.jsp Error
Option A: (your current choice):
JSP:
html:hidden property=regularPlan value=true /
Thanks heaps Pavel!
It was the web.xml header that had sunk me.
Had taken mine from the struts-blank.war except I had rolled it forward to
web-app 2.3
BTW if I'm using JSP 2.0, shouldn't the JSTL tag library definitions for
them be able in the web container?
Ie shouldn't they be contained in one
I am facing issues while the my jsp has to be
pre-popluated with form data in case of from
validation errors.
The issues are :
1. Usage of html:option
I have a requirement where in the value in the
html:option is a dynamically generated value where I
tried to do the following
html:select
I can connect and authenticate via a database no problem. My problem is I
can't compile because of this line,
String userID = session.getAttribute(userID); - gives an error cannot
find symbol variable session
So I changed it to this,
String userID = HttpSession.getAttribute(userID);
...and I
I apologize for the confusion, I was thinking 2 things when I posted.
1 - What was the best design(I'm new to java and struts).
2. How do I solve that specific problem, which may well be a syntax related
issue on the line I specified in the last post.
The web site sets attributes after a user
Hi Mark,
Try changing the 'forward' to 'action' in your html:link tag:
html:link action=signonSign in/html:link
HTH,
Curtis
Mark McWiggins wrote:
... as I seem to get stuck on the simplest things.
For example:
body
html:link forward=signonSign in/html:link br
/body
Thanks,
Mark
I think your going to have a D'oh! moment in just a second... I hope I
don't come across as talking down to you, that's not my intent, but I'm
not sure if your missing some fundamental knowledge, or just made a
typical ARGH! programming mistake like we all do, so I'm going to
answer as if it's
For the first question; I would recommend using LabelValueBean
html:select property=socId
html:optionsCollection property=dropDownValues/
/html:select
You should have a method getDropDownValues which returns a
Collection of LabelValueBeans.
On Sat, 8 Jan 2005 18:27:01 -0800 (PST), meena r
String userID = request.getSession().getAttribute(userID);
or
HttpSession session = request.getSession();
String userID = session.getAttribute(userID);
However, really, as you have been told twice, what you want is:
String userID = request.getParameter(userID);
RIght?
Jack
On Sun, 09 Jan
28 matches
Mail list logo