You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Denis Pasek (JIRA)" <ji...@apache.org> on 2006/07/13 15:21:16 UTC

[jira] Created: (STR-2913) html:errors und html:messages should provide number of messages to header and footer

html:errors und html:messages should provide number of messages to header and footer
------------------------------------------------------------------------------------

         Key: STR-2913
         URL: http://issues.apache.org/struts/browse/STR-2913
     Project: Struts 1
        Type: Improvement

  Components: Taglibs  
    Versions: 1.x Next    
    Reporter: Denis Pasek
    Priority: Minor


One nice enhancement of the Struts' html:errors and html:messages would be that while generating the defined header or footer the number of available messages are used as message arguments. This would facialate a header like "There are 3 error messages" or "There is 1 error message" using a message pattern like this:
errors.header=There are {0} error {0,choice,1#message|1<messages}.
This enhancement should be totally backward compatible since it's currently not possible to add arguments to headers and footers so nobody should have reserverd argument 0 for something.



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/struts/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


[jira] Resolved: (STR-2913) html:errors und html:messages should provide number of messages to header and footer

Posted by "Paul Benedict (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/struts/browse/STR-2913?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Benedict resolved STR-2913.
--------------------------------

    Resolution: Fixed
      Assignee: Paul Benedict

Added new "count" attribute on both <logic:messagesPresent> and <html:messages> tags. Each will expose the count, when specified, of the messages sought. The latter can do all messages or only for the property specified. 

Example:
<logic:messagesPresent count="count">
    <p>There are ${count} error(s) present</p>
</logic:messagesPresent>

The error tag is deprecated. It's not as powerful and deference should be given to message tags.

> html:errors und html:messages should provide number of messages to header and footer
> ------------------------------------------------------------------------------------
>
>                 Key: STR-2913
>                 URL: https://issues.apache.org/struts/browse/STR-2913
>             Project: Struts 1
>          Issue Type: Improvement
>          Components: Taglibs
>    Affects Versions: 1.3.6
>            Reporter: Denis Pasek
>            Assignee: Paul Benedict
>            Priority: Minor
>             Fix For: 1.4.0
>
>
> One nice enhancement of the Struts' html:errors and html:messages would be that while generating the defined header or footer the number of available messages are used as message arguments. This would facialate a header like "There are 3 error messages" or "There is 1 error message" using a message pattern like this:
> errors.header=There are {0} error {0,choice,1#message|1<messages}.
> This enhancement should be totally backward compatible since it's currently not possible to add arguments to headers and footers so nobody should have reserverd argument 0 for something.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (STR-2913) html:errors und html:messages should provide number of messages to header and footer

Posted by "Paul Benedict (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/struts/browse/STR-2913?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=44050#action_44050 ] 

Paul Benedict commented on STR-2913:
------------------------------------

I want to implement this. I've always wanted to output the number of errors or messages too. Let's do this with the MessageTag though. What do you propose for that?

> html:errors und html:messages should provide number of messages to header and footer
> ------------------------------------------------------------------------------------
>
>                 Key: STR-2913
>                 URL: https://issues.apache.org/struts/browse/STR-2913
>             Project: Struts 1
>          Issue Type: Improvement
>          Components: Taglibs
>    Affects Versions: 1.3.6
>            Reporter: Denis Pasek
>            Priority: Minor
>             Fix For: 1.4.0
>
>
> One nice enhancement of the Struts' html:errors and html:messages would be that while generating the defined header or footer the number of available messages are used as message arguments. This would facialate a header like "There are 3 error messages" or "There is 1 error message" using a message pattern like this:
> errors.header=There are {0} error {0,choice,1#message|1<messages}.
> This enhancement should be totally backward compatible since it's currently not possible to add arguments to headers and footers so nobody should have reserverd argument 0 for something.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (STR-2913) html:errors und html:messages should provide number of messages to header and footer

Posted by "Paul Benedict (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/struts/browse/STR-2913?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Benedict updated STR-2913:
-------------------------------

    Fix Version/s: 1.4.0

> html:errors und html:messages should provide number of messages to header and footer
> ------------------------------------------------------------------------------------
>
>                 Key: STR-2913
>                 URL: https://issues.apache.org/struts/browse/STR-2913
>             Project: Struts 1
>          Issue Type: Improvement
>          Components: Taglibs
>    Affects Versions: 1.3.6
>            Reporter: Denis Pasek
>            Priority: Minor
>             Fix For: 1.4.0
>
>
> One nice enhancement of the Struts' html:errors and html:messages would be that while generating the defined header or footer the number of available messages are used as message arguments. This would facialate a header like "There are 3 error messages" or "There is 1 error message" using a message pattern like this:
> errors.header=There are {0} error {0,choice,1#message|1<messages}.
> This enhancement should be totally backward compatible since it's currently not possible to add arguments to headers and footers so nobody should have reserverd argument 0 for something.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (STR-2913) Message tags to expose count of messages

Posted by "Paul Benedict (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/struts/browse/STR-2913?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Paul Benedict updated STR-2913:
-------------------------------

    Summary: Message tags to expose count of messages  (was: html:errors und html:messages should provide number of messages to header and footer)

> Message tags to expose count of messages
> ----------------------------------------
>
>                 Key: STR-2913
>                 URL: https://issues.apache.org/struts/browse/STR-2913
>             Project: Struts 1
>          Issue Type: Improvement
>          Components: Taglibs
>    Affects Versions: 1.3.6
>            Reporter: Denis Pasek
>            Assignee: Paul Benedict
>            Priority: Minor
>             Fix For: 1.4.0
>
>
> One nice enhancement of the Struts' html:errors and html:messages would be that while generating the defined header or footer the number of available messages are used as message arguments. This would facialate a header like "There are 3 error messages" or "There is 1 error message" using a message pattern like this:
> errors.header=There are {0} error {0,choice,1#message|1<messages}.
> This enhancement should be totally backward compatible since it's currently not possible to add arguments to headers and footers so nobody should have reserverd argument 0 for something.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.