You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Ashok Madhavan <as...@yahoo.com> on 2003/06/12 06:02:17 UTC
label for tag
Hi,
Is there any tags in struts for the html label tag.
for example like this,
<label for="firstname">First Name</label><input
type="text" id="firstname">
is this going to be a future feature or is it already
implemented.
regards
Ashok
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
Re: label for tag
Posted by Ashok Madhavan <as...@yahoo.com>.
hi Jeff,
I guess i was not clear in my email.
The <label for....> is used if you want the focus to
be moved to the html form component when any user
clicks on the label description. In the example i had
typed, if you clicked on "first Name", it will move
the cursor to the text box.
you can look at this link for additional info :
http://www.htmlhelp.com/reference/html40/forms/label.html
regards
Ashok
--- Jeff Kyser <kt...@comcast.net> wrote:
>
> On Wednesday, June 11, 2003, at 11:02 PM, Ashok
> Madhavan wrote:
>
> > Hi,
> > Is there any tags in struts for the html label
> tag.
> >
> > for example like this,
> >
> > <label for="firstname">First Name</label><input
> > type="text" id="firstname">
> >
> >
>
> Sorry if I miss your question, but there is
> something like this:
>
> <bean:message key="journalForm.date.displayname"/>
> <html:text property="date"/>
> <html:errors property="date"
> bundle="VALIDATOR_BUNDLE"/>
>
> bean:message lets me output a value from a
> ApplicationResources.properties file
> that I might use as the label for a date entry
> field.
>
> html:text is of course the text entry field for a
> field named 'date' on
> my form
>
> html:errors is the message I will display if there
> is a validation
> error,
>
> don't know if that helps or not...
>
> -jeff
>
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> struts-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
Re: label for tag
Posted by Jeff Kyser <kt...@comcast.net>.
On Wednesday, June 11, 2003, at 11:02 PM, Ashok Madhavan wrote:
> Hi,
> Is there any tags in struts for the html label tag.
>
> for example like this,
>
> <label for="firstname">First Name</label><input
> type="text" id="firstname">
>
>
Sorry if I miss your question, but there is something like this:
<bean:message key="journalForm.date.displayname"/>
<html:text property="date"/>
<html:errors property="date" bundle="VALIDATOR_BUNDLE"/>
bean:message lets me output a value from a
ApplicationResources.properties file
that I might use as the label for a date entry field.
html:text is of course the text entry field for a field named 'date' on
my form
html:errors is the message I will display if there is a validation
error,
don't know if that helps or not...
-jeff
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
RE: label for tag
Posted by Ashok Madhavan <as...@yahoo.com>.
hi Steve,
thanks a lot. i now know how to use it.
regards
ashok
--- Steve Raeburn <st...@ninsky.com> wrote:
> There's no reason to not use the <label> tag.
>
> If you want to externalize the label text you can
> use a struts tag:
>
> <label for="firstname">First Name</label><input
> <bean:message key="prompt.firstName"/>
> </label>
> <html:text property="firstName"
> styleId="firstname"/>
>
>
> Steve
>
> -----Original Message-----
> From: Ashok Madhavan [mailto:ashsud2000@yahoo.com]
> Sent: June 11, 2003 9:02 PM
> To: struts-user@jakarta.apache.org
> Subject: label for tag
>
>
> Hi,
> Is there any tags in struts for the html label tag.
>
> for example like this,
>
> <label for="firstname">First Name</label><input
> type="text" id="firstname">
>
> is this going to be a future feature or is it
> already
> implemented.
>
> regards
> Ashok
>
>
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> struts-user-help@jakarta.apache.org
>
>
>
>
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> struts-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail:
> struts-user-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
RE: label for tag
Posted by Steve Raeburn <st...@ninsky.com>.
There's no reason to not use the <label> tag.
If you want to externalize the label text you can use a struts tag:
<label for="firstname">First Name</label><input
<bean:message key="prompt.firstName"/>
</label>
<html:text property="firstName" styleId="firstname"/>
Steve
-----Original Message-----
From: Ashok Madhavan [mailto:ashsud2000@yahoo.com]
Sent: June 11, 2003 9:02 PM
To: struts-user@jakarta.apache.org
Subject: label for tag
Hi,
Is there any tags in struts for the html label tag.
for example like this,
<label for="firstname">First Name</label><input
type="text" id="firstname">
is this going to be a future feature or is it already
implemented.
regards
Ashok
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: struts-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: struts-user-help@jakarta.apache.org