?
Solved

html logic tags - checking for a collection size greater than 1

Posted on 2011-02-21
2
Medium Priority
?
289 Views
Last Modified: 2012-05-11
I have a collection that I showing on my jsp page.  Im using a html:select tag and I also default the first value to "Please select a filter".  I want this selection to be totally hidden if there are none.  I was trying to use the html tag notEmpty but still shows the selection.  I know the consoleFilters selection  has no entries.  ConsoleFilters has one attribute, filterName.

Current code that is not working....

<logic:notEmpty name="CONSOLEFILTERS" property= "filterName">
     <tr>
           <td>            
        <html:select property="filterNameSelected" style="width: 200px;">
              <html:option value="ALL">Please Select a Filter</html:option>
              <html:options collection="CONSOLEFILTERS" property="filterName" labelProperty="filterName"/>
         </html:select>
            </td>
        </tr>
</logic:notEmpty>
0
Comment
Question by:TheVeee
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 9

Accepted Solution

by:
ioanton earned 2000 total points
ID: 34942802
Try by removing the property attribute:

<logic:notEmpty name="CONSOLEFILTERS">
0
 
LVL 5

Author Closing Comment

by:TheVeee
ID: 34942831
CHA-CHING, Thanks!
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
This article discusses how to implement server side field validation and display customized error messages to the client.
In this tutorial viewers will learn how to embed an audio file in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: : The declaration should display (CODE) HTML5 is supported by the most recent versions of all major browsers…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question