> I'm not really going to be on board with all the generalizations being
> made discussed here though. By generalizing it as much as David has
> suggested, along with ideas being discussed here it would require more
> than just this in our JSP's:
>
> <custom:label key="FormName.fieldName"/>
The generalized tag would be:
<custom:label key="some.label.key" property="fieldName"/>
I don't see that as being much harder to use than the custom version.
> My tag also has another interesting feature. We store our message
> resources in the database. When the user is logged in with a special
> role ("dev" in our case) then the label tag outputs they key names
> rather than their value (making it instantly apparent which text is
> hard-coded into the JSP and which is put into the resources). That key
> is also a hyperlink to a pop-up form allowing the user to enter a new
> value for that resource key.
>
> Another feature of my tag is that if the value of a key ends with '?'
> then the colon is omitted. The label values do not contain colons, it
> is automatically appended to all labels except questions, where a colon
> separator looks a bit ugly.
These 2 features are rather specific to your needs. Customizing a Struts
label tag to add them seems appropriate.
> It sounds like you've done a great job writing tag(s) for your
> particular uses. I think, ultimately, we'll find that a generalized
> tag will be fine for some folks, but just not enough for many of us.
> Given what our tag does, I don't think we'd consider using a
> lesser-featured built-in one (except maybe to subclass it if you guys
> build it nicely enough! :).
Struts can't build in all of the features specific to your app (like the
database functionality). I think an appropriate goal is to create a label
tag that most people can use easily and can be subclassed to add custom
features.
David
>
> > I feel this offers the kind of flexibility and extensibilty that I
> > think
> > Struts needs.
> > Please check out this enhancement at
> > http://issues.apache.org/bugzilla/show_bug.cgi?id=20784
>
> I'll definitely keep my eye on the development of this. I agree that
> something along these lines is what folks need to build webapps with
> Struts. Whether a generalized solution exists still remains to be
> seen. Simple tags to display labels and do what David suggests in his
> comments to the Bugzilla issue, and perhaps a really simple one to just
> show an asterisk (or some custom text) if a field is required would be
> good to have as well.
>
> Erik
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
__________________________________
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!
http://sbc.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]