Inside a nested foreach, accessing the same variable is returning different values. This happens when the page is reloaded, not on first load.
<ui:composition
xmlns="http://www.w3.org/1999/xhtml"
(...)
xmlns:c="http://java.sun.com/jstl/core"
xmlns:h="http://java.sun.com/jsf/html">
...
|
I'm trying to compare two different object in JSF.
A String and an Integer, of cours it don't work...
//myVar ==> Integer object
//myVar2 ==> String
<c:if test="${myVar == myVar2}">
YES!!!!!!!!
</c:if>
I try with myVar.toString ... |
I use JSF-facelets.jar 1.1.14 (I downloaded it here) and tomcat 6.0
Manifest-Version: 1.0
Ant-Version: Apache Ant 1.7.0
Created-By: 1.5.0_12-b04 (Sun Microsystems Inc.)
Implementation-Version: 1.1.14
If I understand well, JSF-facelets.jar = JSF + JSTL + ... |
I'm using Richfaces JSF and I want to iterate over an Map<Object,Object>. I see many examples on Sun forums and other sites but in my case it doesn't work. Here is ... |
I don't like JSF but I need to solve this problem with it, I am working in "pure" JSF.
So this is what I baisicly need but I don't know how to ... |
i make a JSF 2.0 Application and i use many h:inputText fields to input data in my database. Some fields are not required
<h:inputText value="#{registerBean.user.phoneNumber}" id="phoneNumber" >
...
|
I have two strings that i need to compare, but even if they have the same values or different , it always enters the statement...
<c:when test="#{bean.name1 != ...
|
|
where can i find schema definitions for
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:c="http://java.sun.com/jstl/core"
?
|
Trying to use JSTL but have the following problem:
Index.xhtml page:
<?xml version="1.0" encoding="UTF-8"?>
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
...
|
I have 7 drop down in my jsp(Using JSF tag-Select One Menu), 2 drop downs are dependent on other 2 drop downs. The scope of my Managed Bean is session.I have ... |
I can access my variable stored in a backing bean from my JSF2 page, so things like
<h:outputText value="#{myBean.myValue}"/>
work, and the value (which is an int btw.) prints okay.
However, when trying to ... |
When I want to hide some content in JSF, what tag is made for this purpose? There are several tags that can do the job:
<f:subview rendered="#{...condition...}" />
and
<c:when test="#{...conditon...}" />
Which is the ... |
I have a xml file which I want to transform in a jsf code page. To do that I've created a xsl file.
xml:
<?xml version='1.0' encoding='ISO-8859-1'?>
<questionario xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
...
|
Hi I got the following code:
<?xml version="1.0" encoding="UTF-8" ?>
<!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"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:p="http://primefaces.prime.com.tr/ui"
xmlns:c="http://java.sun.com/jsp/jstl/core"
>
<h:body>
<c:forEach ...
|
I have this piece of code:
<c:if test="#{utils.getCounterOfCharOccurence(hideTypes, ';') != 0}">
<ui:repeat value="#{document.instanceList}" var="instance">
<c:set var="columnRendered" value="true"></c:set>
<c:forEach items="${hideTypes.split(';')}"
...
|
I use <c:foreach> in my jsf app to iterate over a list of people. I don't use <ui:repeat> because every person has its own tab (primefaces). JSF hero 'BalusC' already helped ... |
i have populate some values using c:forEach tag. I want to get those values in my javascript.
If I click GetCtag value button, then i want ...
|
I have used c:forEach loop for display the list of images using h:graphicImage. But I can't display the images. I have the h:commandLink also in my page. The image have to ... |
I'm puzzled because of build and run errors that mislead me. From them, I can't quite figure out what the distinction is between the various JavaServer Page Standard Tag Libraries. For ... |
I am trying to display a <h:outputText> or <h:commandLink> accordingly to a String property returned by a backing bean.
I am having problems when comparing the strings..
Here is the illustration:
<c:if test='#{column.header ne ...
|
I am trying to add a h:graphicImage after the f:selecItem element, using this declaration:
<h:selectManyCheckbox layout="pageDirection">
<f:selectItem itemValue="some Value" itemLabel="some Label" itemDisabled="true">
...
|
I know this may have something to do with the phase each one comes in at.
If I do this.
<ui:repeat id="repeatChart" varStatus="loop" value="#{viewLines.jflotChartList}" var="jflotChart">
...
|
I'm trying to use JSTL with JSF 1.1. The following code is causing me a problem:
<c:forEach var="key" items="${names}">
<h:column>
<f:facet name="header">
...
|
Facelet:
<h:dataTable value="#{item1.zapas}" var="item2" >
<h:column>
<h:outputText value="#{item2.hrac == null}"/>
<c:choose>
...
|
I have problem with core tag in JSF. Im using this tag for pagination button rendering. There is one big problem - when there is more then 127pages. Iteration value ... |
I have written a piece of code in jstl . I am getting the following error while executing the html.
Can I call a method in value attribute for c:set.If not please ... |
i am trying to include a java code into the value of the inputText in my jsf page but an error occur
according to tld or attribute directive in tag ... |
Consider the following jstl choose:
<c:choose>
<c:when test="#{AuthMsgBean.rw['2'] ne null}">
Display Text
</c:when>
<c:otherwise>
...
|
I faced this situation quite a few times, and I found my solution but not sure if it's a good one.
I need to call some service which interacts with ... |
i want to know what version of JSTL to be used with JSF 2.1 on tomcat 7
please advise, thanks.
|
I'm doing a page with jsf 2.0 and i wanna do something like this:
<f:metadata>
<f:viewParam name="id" value="${id}" />
<f:event type="preRenderView" listener="#{controller.initPage(id)}"/>
</f:metadata>
....(Some code)....
<c:forEach items="#{bean.listLoadedByInitPage}" var="var">
...
|
I have two list that consist out of the same object.
I want to check if the first list containts an object of the second list
<ui:repeat var="item" value="#{userTypeController.permissionItems}">
<c:if ...
|
|
|
I've read various messages and articles that discourage the use of JSTL in JSF pages, and I think I understand the reasoning behind that. However, I'm hoping that there is a better way to format dates and numbers for display than just returning the formatted String value from the managed bean. If I have a person bean, with properties hireDate and ... |
hi, i read that link and i think it was hard to understand for me. but what i understood was i have to change some tag lib and that they have written that it only works in Glassfish. is that Glassfish server? pl let me know am i correct? i m using Tomcat server. any other link or any other solution ... |
Hi, Can I use JSTL tags with JSF? I am trying to use it, but JSTL tags are not working, probably the bean in request is not visible to jstl tags. I am using this to have the bean available in request scope <%-- jsf:pagecode language="java" location="/JavaSource/com/dest/web/pagecode/LogView.java" --%><%-- /jsf:pagecode --%> When I use the jstl tags works fine, but I ... |
Hello all i started to use jsf , and i downloaded the jakarta.apache jstl 1.2 tag lib now im trying to find somekind of reference to the html tag lib for example the core i found in sun site . can someone please point me to the reference api ? or examples? thanks |
|
|
|
Hi guys, Could you please answer some if my doubts below regarding JSF & JSTL on the same page ? Doubt #1 : Is there some way to dynamically construct a page where the columns are variable by using a dataTable tag ? What I need is basically show some items on columns instead of rows as the dataTable tag actually ... |
|
|
|
<%@ page language="java" pageEncoding="ISO-8859-1"%> <%@ taglib uri="http://java.sun.com/jsf/html" prefix="h"%> <%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%> <%@ taglib uri="http://java.sun.com/jstl/core" prefix="c"%> Test Page |
Thank you for your reply. Unfortunately, In JSF 1.2 RI, the UI does not have the attribute "var", so, the below code does not work. I think, this can't be done JSF1.2 UI. As you suggested, I might need to add Tomahawk into my application. Please let me know if there are any other solutions. I am using richfaces with ... |
|
|
|
|
|
|
I have a simple seam project created in Eclipse.All my web pages have extension xhtml and I access each of them by typing page_name.seam.I would like to restrict access to every other page other than login page if the user is not logged in.I tried to use tag but it didn't work.Other c: tags won't work either.Can anyone tell me ... |
|
Thanks bear! I really appreciate that. To be very honest, I am planning to make my own website(web application). So, I am looking for some book which could give me practical examples that I could refer to while creating my web pages. (I am going to be using Struts). Could you kindly suggest a good book on JSP/JSTL. |
Tim Holloway wrote: What you are doing wrong is mixing JSTL with JSF. I won't say you should never do that, but I haven't found a good reason to use JSTL on a JSF page ever and I've been working with JSF since about 1985. I thought that this was the best way to do the condition, since I'm working with ... |
Acutally, what they did was get rid of the idosyncratic per-framework expression languages and merge them all into a Unified Expression Language (UEL). Makes the rules more consistent and voids the need for separate parsing, interpreting and support facilities. The primary difference between the "$" and "#" indicators is that "#" indicates a reference and "$" indicates a value. Specifically, since ... |
After a year working with JSF I did not expect to be encountering problems like this - but then I don't use jstl much so perhaps I'm just missing the blindingly obvious! I can run this code with the backing bean property teamCreateView.countryIsSet set to true and get the output: true Output 2 Output 4 true When I run is with ... |
|
|
So you have an application coded with JSP and Dojo, why you want to rewrite it (assuming it is working)? It is not logical to say which one is advanced since each one of them is different from the another. JSP is a template technology, JSTL is a supporting tag library and JSF is a component-based framework. You are the one ... |
|
Hello! I'm trying to use the jstl tag if, but it doesn't work. I'm sure the condition is false, but it gets into the if anyway. XXXX !!! I've searched a lil bit: With Facelets, JSTL evaluations happen at compilation time, whereas other EL evaluations happen at render time. This ... |
JSP stands for Java Server Page. A jsp is a file with a .jsp extension that when placed in a servlet container (Typically Tomcat) will be converted by the servlet container into a java file then compiled to run as a servlet. Typically this servlet is used to service a client http request. For instance a login screen with a username ... |
|
Hello, I need urgent help ... I am with the following problem. I've posted a jsp page with jsf. I use tomcat 5.5.30 and when I try to access my page gives the following error: type Status report message / admin / login.jsf description The requested resource (/ admin / login.jsf) is not available. My question is this .. I read ... |
I'm having problems doing what should be very simple. Trying to extend my JAVA knowledge which is limited to pure JAVA, not J2EE. To do so, I downloaded Eclipse (latest build) and Tomcat (v5.5). Everything appears to run fine, but I'm having problems running a simple JSP page (with JAVA Server Faces). FYI, I'm on Mac, running latest Leopard build. - ... |
|