Using the tag c:if in a4j:repeat

Can i use <c:if> in repeater tag block? If not please suggest something else.
My code:
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<a4j:repeat var="elm" value="#{dgel.listelements}">
          <c:if test="#{elm.class.name == 'beans.TagLabel'}">
               <h:outputLabel value="#{elm.class.name}" />
          </c:if>                                   
</a4j:repeat>
dgel.listelements - is ArayyList
Condition code is not working.

It must be possible if you were using at least JSF 1.2 + JSTL 1.2 at a Servlet 2.5 + JSP 2.1 playground.
But why don't you just use the 'rendered' attribute for this?
<h:outputLabel value="#{elm.class.name}" rendered="#{elm.class.name == 'beans.TagLabel'}" />

Similar Messages

  • Can you use the  tag in mail?

    I was reading about sub-addressing in email accounts. It was suggested to use the +tag with your email address, such as: [email protected]
    Any idea if this works with Apple Mail, and if so how to go about it?.
    Thanks

    iCloud: Create or change email aliases

  • Using the Tag Query's Statistics Mode

    I've tried to come up with the average of tag values over a span of a month two different ways:
    1.  using the Statistics mode
    2.  using the HistoryEvent mode and averaging the resultant data with an average function.
    For most tags the two results are quite similar.  I have one tag however that contains a lot of zero values and for that tag, the Statistics mode average is about 10% higher than the HistoryEvent mode average. It's like the Statistics mode ignores the zero values when doing it's calculations.
    Is this correct?  My tag query is returning data from six tags - does this cause the Statistics mode any heartache?
    David Macindoe

    David,
    Martin K - if you are listening please feel free to correct or confirm the following:
    The PI UDS uses native Statistical method calls to the PI API/SDK, so the results are coming directly from PI.  In this case, xMII is not doing a HistoryEvent call and then doing the average calcs on the raw event records, like it would be if you did it in BLS.
    Regards,
    Jeremy

  • Problem using the tag validatorMessage on inputText

    In essence when there is an error i want as output what i write as string on validatorMessage.
    <h:inputText id="data_scadenza" value="#data_scadenza}" 
    validatorMessage="Data scadenza errata" >
    <f:convertDateTime pattern="dd/MM/yyyy" />
    </h:inputText>Instead i obtain always the default message on English.
    Note:
    I use JSF 2 on Glassfish 3.
    Edited by: alelinuxbsd on 5-mar-2010 10.39

    <h:inputText id="data_scadenza" value="#data_scadenza}" 
    converterMessage="Data scadenza errata" >
    <f:convertDateTime pattern="dd/MM/yyyy" />
    </h:inputText>Many thanks.
    I have better interest about JSF only after the exit of JSF 2 so i don't known well these things.

  • How to use HTML Tags in Smartforms

    Hi,
    Can you please help me out in knowing how to use HTML tags in Smartforms,
    suppose i want to display some text in BOLD i should use the tag </b> as shown
    </b>  Header Information <b>
    regards
    Ranveer

    Hi Ranveer ,
        check this following links,
      hope this wil helps you
    <a href="http://sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/webas/abap/abap%20code%20samples/smartforms/smartform%20in%20abap.pdf">check this link,to know abt HTML in smartforms</a>
    rgds,
    shan

  • My app can't see the tag library

    Hi everybody,
    I am developing an application in JSP which accesses an Oracle database and display the results to the user.
    I am using the tag "exceltag.jar" taken from "http://www.servletsuite.com/servlets/exceltag.htm" to convert an html table to an excel sheet. This works fine on my computer but it fails after we installed the application to our web server, running Tomcat 4.1.12.
    The "exceltag.jar" file has been placed under 'WEB-INF\lib' and the classpath has been set to point to that location. However when I attempt to convert the html table to an excel sheet by clicking a button, I get the following error:
    java.lang.NoClassDefFoundError:
    javax/servlet/jsp/tagext/BodyTagSupport at java.lang.ClassLoader.defineClass0(Native Method) at
    java.lang.ClassLoader.defineClass(ClassLoader.java:509)
    It seems like the application can't see the "exceltag.jar" file.
    What do I need to do to overcome this problem?
    Thank you very much.

    The servlet.jar is in TOMCAT_HOME/common/lib. Since all the JARs in that directory are automatically added to the CLASSPATH and are visible to all applications running under Tomcat, you don't have to do anything for the class loader to find it.
    Your app's WEB-INF/lib directory JARs are also automatically added to to the CLASSPATH. That's the correct place to put that exceltag.jar, by the way, not the TOMCAT_HOME/common/lib.
    As a matter of fact, if you have a system CLASSPATH, be sure that Tomcat ignores it completely. You shouldn't even have one, IMO. (I don't.)
    When I open up the servlet.jar in my TOMCAT_H0ME/common/lib, I can see a class named BodyTagSupport with path javax.servlet.jsp.tagext. You should, too.
    In your exceltag.jar, you should find a TLD for the library. Open that with a text editor and make sure that the text under the <uri> tag matches that in your JSP. For example, I use the JSTL tag library. The c.tld has this <uri> tag:
      <uri>http://java.sun.com/jstl/core</uri>My JSPs that want to use the core tag library have this near the top of the page:
    <%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>Notice how the URIs match. That's what yours should do, too.
    If you don't find a TLD inside the exceltag.jar, that means they didn't package it properly. - MOD

  • Iphoto 9.5 won't import photos from iPhoto 7.5.  Library will not update using the iPhoto library upgraded application.

    iphoto 9.5 won't import photos from iPhoto 7.5.  Library will not update using the iPhoto library upgrader application.  Repeatedly says it can't locate photos even when told to cancel.  I think the photos in question are in Nikon RAW format.

    iPhoto 9.5 immediately tries to "upgrade" my library using the upgrader.
    iPhoto 9.5 asks you to run the upgrader to prepare the library for 9.5. It then will update the library to its format.
    You need to do the following:
    1 - go to your Applications/Utilities folder and double click on the iPhoto Library Upgrader 1.1 application. 
    2 - select Choose Library, navigate to your iPhoto library, select it and let the upgrader do its thing.
    3 - launch iPhoto 9.5 to open and finish the conversion of the library.
    OT

  • Problem with the tag color in the richText

    Morning,
    I want to modify by html the color of a word in a richtext field.
    I know I can use the tags <b>bold</b>, <i>italic</i> in the richtext Field for one word. Which tag to use to change the color?
    Could you help me please?
    Thanks by advance.
    Josijosi

    Here is an example of the sting "This is a test " where the word test is in a different color.
     <body xmlns:xfa="http://www.xfa.org/schema/xfa-data/1.0/" xmlns="http://www.w3.org/1999/xhtml" xfa:APIVersion="Acroform:2.7.0.0" xfa:spec="2.1">
       <p style="margin-top:0pt;margin-bottom:0pt;text-valign:middle;font-family:'Myriad Pro';font-size:10pt;text-decoration:none">This is a<span style="xfa-spacerun:yes"> </span>
        <span style="color:#ff0000">test</span>
       </p>
      </body>
    Paul 

  • How to get the JSP Name calling the Tag Library inside the Tag Library

    Hi guys,
    I have defined a Tag Library PenStart:
    import javax.servlet.jsp.tagext.*;
    public class PenStart extends TagSupport
      public int doStartTag()
        return EVAL_BODY_INCLUDE;       
      public int doEndTag()
        return EVAL_PAGE;
    }I have also defined the pentags.tld:
    <taglib xmlns="http://java.sun.com/xml/ns/j2ee"
              xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
              xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee web-jsptaglibrary_2_0.xsd"
              version="2.0">
         <description>My Tag Library</description>
         <tlib-version>1.0</tlib-version>
         <short-name>pentags</short-name>
         <tag>
              <name>penstart</name>
              <tag-class>com.srh.tag.PenStart</tag-class>
              <body-content>empty</body-content>
         </tag>
    </taglib>I am calling the tag library in my JSPs:
    <%@ taglib uri="WEB-INF/pentags.tld" prefix="pen"%>
    <pen:penstart/>Now in the doStartTag() I want to know the JSP which is using the tag. How can I do that?
    Thanks

    pageContext.getRequest().getRequestURI()

  • Using structure tag in a catalog search

    Hi there,
    I would like to select numbers on docs that have been scanned and OCR, and search for these numbers via a catalog.
    I tried to use the tag panel in the reading order panel, to create
    1) a root tag,
    2) then having selected the number, I try "define a tag from the selection" (or something like that, I have a french interface) to apply a Form tag to that number.
    Then I build a catalog (a pdx file) and I try to add the structure tag : I have play with <Form>, Form, Formulaire, <Formulaire> .... it does not work. Despite the message that the index is well done, the numbers I have taged are not found when searching with the index file. Another way to go would be with metadata, but I would have to enter what's already in the pdf...
    Thanks for any advice on this !
    François

    François,
    Tagged search from Catalog works only on tagged document (the entire document should be tagged, not just one element).
    Try this -
    1. Tag your original document by using the option in Advanced>Accessibility.
    2. Now add specific tags to the document which you are interested in.
    3. Close the document and build a .pdx of out it (use exactly the same tag name that you specified in 2)
    4. Load the index in Search, you should see your tag name in the drop down in advanced search and the search should work.

  • Is it possible use jsf tags in a desktop client?

    How can I use the tags for jsf for example <h:view .../> in a desktop client?

    You probably could if you try hard enough. For starters, use Facelets instead of JSP; that drops the need for a Java compiler and other things. Then you will need to supply the equivalent of the FacesServlet. Any underlying technology usually supplied by the container would need to be supplied by you. You will also need a first rate browser embedded in your application, with JavaScript support.

  • How do I install and use JSP tags?

    could some one show me how to use the tags that is available in http://www.servletsuite.com/jsp.htm? It comes with .jar and tld but I have no idea what to do with them. I am new to JSP so please forgive me if it is a dumb quesion, Thanks.

    See my code below, I can use the sql and core but I cannot use the dbtag, it complains unable to connect. I am not sure if I enter the driver and URL correctly. Hopefully that is the right format.
    <%@ page contentType="text/html; charset=iso-8859-1" language="java" import="java.sql.*" errorPage="" %>
    <%@ taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql" %>
    <%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
    <%@ taglib uri="http://www.servletsuite.com/servlets/dbtag" prefix="dbtag" %>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml">
    <head>
    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
    <title>Untitled Document</title>
    </head>
    <body>
    <sql:query var="rs" dataSource="jdbc/SangwebDB">
    select name,username,email from sangweb_users
    </sql:query>
    <h2>Results</h2>
    <c:forEach var="row" items="${rs.rows}">
    name ${row.name}
    email ${row.email}
    </c:forEach>
    <dbtag:openConnection driver="com.mysql.jdbc.Driver'" url="jdbc:mysql://localhost:3306/sangweb?autoReconnect=true" user="testuser" password="testuser" id="A"/>
    <dbtag:ifError id="A">
    <br>Could not connect to database
    <br>Error is: <dbtag:getError id="A"/>
    </dbtag:ifError>
    <dbtag:setQuery id="A" query="select name,username,email from sangweb_users" res="B" />
    Found <dbtag:getCount res="B"/> records
    <dbtag:closeConnection id="A" />
    </body>
    </html>

  • Paging using page tag Library

    My JSP is using page tag Library. When I click the Next page it returns next page. How can I change my JSP using page tag so that when the next/previous link is clicked, I should see the next/previous 10 records and so on.
    Thanks in advance

    Unfortunately my mind reading powers are not working so well right now.
    Which page tag library are you using? There are several.
    I would suggest that you look at the documentation for that library.
    Unless you show us what the code you are currently using is, we can't suggest changes.
    Oh, and please don't just copy paste your whole JSP here. A relevant excerpt of how you are using the tag library and how you create the links should be more than enough. And please use code tags.

  • Complex Query using ViewCriteria tag??

    Hi
    I would like to know whether a query with combination of "And" and "Or" conditions can be achieved using ViewCriteria, CriteriaRow and Criteria tags.
    For eg: the SQL query should look like this
    select * from <table name>
    where column1 = x
    and (column2=y or column3=z);
    I tried couple of combinations using the tags but could get either "AND" or "OR" but not combination of both.
    Any suggestions would help.
    Thanks

    With the built in ViewCriteria implementation you cannot do and/or as per your example. But an equivalent query:
    where (column1 = x and column2 = y) or (column1 = x and column3 = z)
    is doable.

  • The tagging service is unavailable - Managed Metadata Service issues

    After SP1 I am unable to use the tagging service in my test farm of SharePoint 2013. Users see the error message popup "The tagging service is unavailable. Please try again later."
    I've ensured that the Managed Metadata service is up and running and is the location for keywords.  I've tried deleting and re-creating the service to no avail.
    Any ideas on what might be happening?  The service looks fine, the database looks fine but no tagging....

    Hi,
    According to your post, my understanding is that you were unable to use the tagging service.
    Per my knowleadge, even if the Managed Metadata Service is associated with the web application and term store is accessible from within the site collection, it still needs to be set as the default for the web application.
    To set the service as the default you need to click on the proxy service, and then select the top two check boxes.
    For more information, please refer to:
    The tagging service is currently unavailable
    Tagging Service is not available when using hashtags in Microblog entry
    Thanks,
    Jason Guo
    Forum Support
    Please remember to mark the replies as answers if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact
    [email protected]
    Jason Guo
    TechNet Community Support
    Jason - thanks for the input.  Unfortunately the service was already set to the default for the web app (both top checkboxes are already checked.)  The service looks identical to my Prod and DR farms, but simply doesn't work.  I've blown it
    away and recreated it without success.

Maybe you are looking for