Solved

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

Posted on 2011-02-21
2
282 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
2 Comments
 
LVL 9

Accepted Solution

by:
ioanton earned 500 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

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

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

Building a website can seem like a daunting task to the uninitiated but it really only requires knowledge of two basic languages: HTML and CSS.
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…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…
In this tutorial viewers will learn how to embed Flash content in a webpage using HTML5. Ensure your DOCTYPE declaration is set to HTML5: "<!DOCTYPE html>": Use the <object> tag to embed Flash content.: To specify that the object is Flash content, d…

803 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