Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
84 views

Why does my managed beans are not working?

I've installed a primefaces theme and then when I run the project some xhtml files don't display well. I inspected the code and I realize that there instead of putting the css link in the href tag ...
Charlie's user avatar
0 votes
1 answer
150 views

Best practice for storing and reading data from Java Beans in XPages

I have the following Java bean code that stores a list of tabs in an ArrayList<String> in a sessionScope, so I do not have to look it up for every request. public class BeanMethods { ...
Thomas Adrian's user avatar
1 vote
1 answer
191 views

@ViewScoped bean behaves like @SessionScoped or @ApplicationScoped

I have a Spring Boot application using JSF/CDI. Backing beans are annotated with @Named @ViewScoped, but while browsing between other pages values still stay on textboxes. Values should've been ...
SmokingTurtle's user avatar
0 votes
0 answers
1k views

jakarta.servlet.ServletContext from jakarta.faces.context.FacesContext to getAttribute("AnAttributeName")

This is a piece difficult,It's JSF i'm using jakarta faces api 3.0.0 , it seems in a ManagedBean calling FacesContext to acquire the jakarta.faces.context.ExternalContext and use its getContext method ...
Samuel Marchant's user avatar
0 votes
1 answer
182 views

CDI injection of subclasses of session scoped beans as a managed property

I am using JSF 2.3 and I want to inject different sublaccess of a session scoped bean as a managed property using CDI. From the link below How to inject different subclasses as ManagedProperty JSF 2? ...
Alex Mi's user avatar
  • 1,459
0 votes
0 answers
22 views

Get JSF managed bean by name in a Servlet [duplicate]

Some months ago I posted my question Accessing @SessionCoped @Named beans from a HttpSession which was marked as a duplicate because of the already answered quesiton Get JSF managed bean by name in ...
Alex Mi's user avatar
  • 1,459
2 votes
1 answer
386 views

JSF - Appropriate bean scope for keeping data between pages but only "browser tab related"

I am creating a web application using JSF 2.2.20 in which I am implementing a "kinda wizard" flow which lets the user filling input fields and go back and forth the view pages through ...
NickAth's user avatar
  • 1,112
0 votes
0 answers
341 views

javax.faces.component.UpdateModelException: javax.el.PropertyNotFoundException. Target Unreachable, identifier resolved to null

Solution of this question already exists in stackoverflow. Although I have asked this question, it is because all available answers doesn't solve my problem/error. So I have asked this question so ...
paawan's user avatar
  • 111
0 votes
0 answers
71 views

How to pass a variable value from one xhtml to another xhtml and then to the backing ManagedBean of 2nd xhtml [duplicate]

I am working on a JSF project. It's using JSF-2 version. I have a test.xhtml which includes another XHTML, below is the code:- <ui:include src="/WEB-INF/genericTag.xhtml" > ...
Jerry's user avatar
  • 331
1 vote
0 answers
42 views

faces-config.xml keep updating itself

I have 2 faces-config.xml file. I created a new page and added bean into the second file. However, the first faces-config file automatically keeps adding bean to it as well. Thus, every time I tried ...
nana21435's user avatar
0 votes
0 answers
40 views

How to determine coordinates of different areas in h:graphicImage

I am writing a JSF app that's similar to the dukes-bookstore case study in the Java EE tutorial. In the dukes-bookstore example the h:graphicImage consists of 6 areas, each displaying a book in the ...
Darvin's user avatar
  • 158
0 votes
0 answers
307 views

JSF cant resolve bean in xhtml file using spring boot

i have a simple JSF xhtml page contains xml: <h:body> <h:outputText value='#{someBean == null ? "null" : "not null"}'/> </h:body> my faces-config contains: &...
Ali Dahaghin's user avatar
0 votes
1 answer
140 views

faces-config.xml is being overwitten

I have created a java bean and updated the faces-config.xml so it can run in my xpages - but the faces-config.xml is being over written. I am assuming this is designer doing this but the file does not ...
Tim Savigar's user avatar
-2 votes
1 answer
223 views

search and display person by id in jsf

I have created a table in my database and saved some data of people using a form that I've created in jsf, now what I want is to be able to enter an id of any person I want and when I click on search ...
enila's user avatar
  • 1
0 votes
0 answers
334 views

Customize PointLabels in PrimeFaces chart

Need some reference to customize the pointLabels in a PrimeFaces redered chart, I'm already using the property of setShowPointLabels as true in my Java Class, but it actually gives me no parameter to ...
viniciusmfelix's user avatar
0 votes
1 answer
401 views

Problem including another XHTML page in an XHTML page

I am a beginner programming Java and I am doing a project using primefaces. I want to include another XHTML page in an XHTML page. The include page is in /WEB-INF/facelets/include.xhtml (It has some ...
Elena's user avatar
  • 1
0 votes
0 answers
231 views

Invalidate session followed by redirect recreates the bean

Working on a JSF validator method defined in a @SessionScoped bean: public void doValidation(FacesContext context, UIComponent component, Object value) throws ValidatorException { // throws ...
bdeo's user avatar
  • 113
0 votes
1 answer
498 views

Problem with spring defined @ManagedProperty

I'm currently mantainning a Maven based JSF Web Application combined with Spring Framework and JPA and connected to a SQL Server database. Inside the application, I created one @ManagedBean class ...
mrcoar's user avatar
  • 186
0 votes
1 answer
49 views

How to direct call xhml page from ManagedBean based on action method return string without faces-config.xml file

1. ManagedBean class @Named public class LoginBean{ private String username; private String password; private String userType; // setter getter public String login() { ...
Jimmy's user avatar
  • 1,033
0 votes
1 answer
133 views

NPE in @ManagedBean - javax.servlet.ServletException: An error occurred performing resource injection

I have Spring project, now I want to add few JSF (Primefaces) xhtml pages, but I get null pointer exception in my @ManagedBean on @PostConstruct method when i try get data from existing services? Do ...
mtmx's user avatar
  • 927
0 votes
0 answers
22 views

Target unreachable, identifier "searchBean" resolved to null [duplicate]

I hope you are doing well. I just got this error, I don't know its source. Could someone help me please. I create a managedBean and give it a name, then call it and JSF code followed by the method ...
HelloWorld007's user avatar
0 votes
0 answers
76 views

Second javabean created not being read by Xpages domino designer 10

I have just started using managed beans in Xpages. The first bean I created worked perfectly. However any new beans that I create or if I edit the first bean does not reflect when I try to use them in ...
Muhammed Ismail Carrim's user avatar
0 votes
1 answer
333 views

Mutable object state replication across distributed web sessions

I'm wondering why there is no single notice about the importance of immutability property when storing serializable objects in the HTTP session? I tried to check the JSF and Servlet API specifications ...
tsobe's user avatar
  • 179
1 vote
1 answer
1k views

Undefined component type javax.faces.ViewRoot in JSF 2.3 startup

This is a new twist from my earlier issues found here. I'm upgrading from MyFaces 2.1 to 2.3.5, and from PrimeFaces 6.1 to 7. This has also included migrating from managed beans to CDI. At this ...
Didjit's user avatar
  • 805
0 votes
0 answers
479 views

How to fix this error,ClassCastException, when i am trying validate my jsf input

This is my code main.xhtml. I am trying validate the input. This is a method-validator: public void validateCorseCode(FacesContext context, UIComponent component, Object value) throws ...
Артем's user avatar
0 votes
1 answer
229 views

Use many beans from the same class, different scopes

I want to use a ManagedBean class, Users.java, to create 2 bean instances with different scopes. I tried to do this in 2 ways: 1. Use ManagedBean and SessionScope annotations for Users (this creates ...
Catalin Vladu's user avatar
0 votes
1 answer
176 views

data from form select menu being passed as null from jsf/html form

I am currently having difficulty passing the value for action variable that is populated when the user selects a select item and clicks the submit button should be written in the logs and not ...
Mike's user avatar
  • 17
1 vote
0 answers
50 views

Hi,It may be a same issue on spring Autowiring,but still i cannot find a solution

I'm trying to create basic CRUD operations using JSF 2.2, Spring 4.01, and Hibernate. From register.xhtml, if I click the register button, then it should save firstname (as of now) in the database. I ...
swats's user avatar
  • 11
0 votes
1 answer
265 views

Add ManagedBean to JSF context at runtime [duplicate]

I'm trying to create a plugin/componentFramework with Java for WebApplications. I'm using Tomcat9, JSF(2.1.13) and Java 1.8. I have a .war File. When i deploy this .war file to Tomcat on startup a ...
JavaDreamer's user avatar
0 votes
0 answers
124 views

Wildfly 12 - Communication between 2 WARs within EAR - JSF Beans (@ManagedBeans / @Named)

Is there a way to perform a communication between WARs within an EAR deployment archive in such a way that it would be possible not just to make usage of JSF Managed Beans (annotated as @ManagedBean ...
LucDaher's user avatar
  • 157
1 vote
0 answers
26 views

ManagedBean injection out of JSF lifecycle [duplicate]

I would like to know if the approach I am following is the correct one and in that case how to solve the following causality. I have a ManagedBean application for the distributed access of the NOSQL ...
Diego's user avatar
  • 13
0 votes
1 answer
173 views

JavaScript Function Load on Startup and Pass Parameters to Managed Beans [duplicate]

I want to load JavaScript function on startup with window.onload and that function would pass its parameters to a Managed Bean. Without a commandButton. JS: window.onload = function getVars() { ...
MertTheGreat's user avatar
0 votes
1 answer
76 views

Managed Bean implicit routing not working?

I am having trouble navigating implicitly from managed bean, the page is a login page containing username and password fields, used to check with phpmyadmin database; My managed bean is defined ...
oflcad's user avatar
  • 515
0 votes
1 answer
1k views

Error Rendering View[null] after ManagedBean method call

I have a jsf page linked to a ManagedBean using Spring with JSF. The page has a button, which calls a method on the bean to update one/multiple rows in the database. The button code is : <t:...
a.hrdie's user avatar
  • 716
0 votes
2 answers
1k views

selectOneMenu does not change the value of the bean object

So I have the following code: <h:inputText value = "#{listAllBookings.searchText}"> <f:ajax listener="#{listAllBookings.printValues()}" event="keyup" render="myTable"/> </h:inputText&...
Lebron11's user avatar
  • 656
1 vote
1 answer
145 views

Datatable does not show values

I have a list of Hotel objects and I want to display the values of each object in a jsf datatable. The problem I am having is that although the table creates a row for each hotel object, the values ...
Savan Luffy's user avatar
2 votes
2 answers
454 views

How to call an ArrayList stored in applicationScope from another class

I want to call an ArrayList stored in applicationScope from another class I have a class, something like this that stores a bounch of data in a public variable names AL_data, the method getAllData ...
Thomas Adrian's user avatar
0 votes
0 answers
272 views

ManagedBean depricated. Using CDI Bean doesn't work

My IDE indicates ManagedBean as depricated. I have read about this and decided to replace my javax.faces.bean.ManagedBean annotations to javax.inject.Named. But when replaced, my CDI Bean is not ...
mcfly soft's user avatar
  • 11.6k
0 votes
0 answers
669 views

How CDI bean vs Managed bean

I have previous experience with Java SE and I've just decided to learn JSF. I'm working with JSF 2.2, Apache Netbeans 10, glassfish 5/paraya 5.184. The problem is, I've been having series of issues ...
Yemi Kudaisi's user avatar
-1 votes
1 answer
2k views

Why Primefaces commandButton does not redirect to the page?

I use primefaces version 6.2 in combination with jsf and trinidaad. In the project I have a table with each row containing a button to redirect this page to another page based on selected row. jsf ...
itro's user avatar
  • 7,218
0 votes
0 answers
35 views

How to pass object between different pages and beas in JSF? [duplicate]

I'm facing some problems using the beans and pages with JSF, when I need to pass an object between two different beans/pages. The idea is to have a page, where I've the list of all the orders, with ...
I love coding's user avatar
0 votes
1 answer
49 views

Unable to set property newsLookupService for managed bean newsManager

I spent lot of time on unable to set property for managed bean problem and read other posts but still cannot find a problem. What can be reason of that problem? Below is StackTrace, interface ...
darco's user avatar
  • 1
0 votes
1 answer
679 views

Update Nested Panel from Backing Bean

I have a panel with sections. Each section is separated by a div and has elements in it. I’m trying to update some of the sections from the backing bean based on a poller. The poller calls a bean. ...
Alan's user avatar
  • 75
1 vote
1 answer
4k views

@ApplicationScoped beans get constructed more than once

I have two managed Java beans: import javax.annotation.PostConstruct; import javax.faces.bean.ApplicationScoped; import javax.faces.bean.ManagedBean; import javax.faces.bean.ManagedProperty; import ...
Giorgio's user avatar
  • 5,163
0 votes
2 answers
196 views

How to use spring DAO methods with Managedbean object? [duplicate]

I have this ManagedBean: @ManagedBean(name="studentItem") @ViewScoped public class StudentBean implements Serializable { private static final long serialVersionUID = 1L; @ManagedProperty("#...
Majid's user avatar
  • 14.2k
0 votes
1 answer
539 views

Access attributes valueExpression in ManagedBean

I have a custom facelet tag which simply includes an outputText. Reason for using a custom tag is to modify the value depending on the entity field. For ex: if the outputText is used for a percentage ...
Cadrian Brown's user avatar
0 votes
1 answer
191 views

jsf commandButton managedBean action redirect to 404 page

I have my ManagedBean TodoService.java package com.medkhelifi.tutorials.todolist.services; import com.medkhelifi.tutorials.todolist.models.dao.ITodoDao; import com.medkhelifi.tutorials.todolist....
medkhelifi's user avatar
  • 1,121
3 votes
1 answer
123 views

session-scoped managed bean appears to be not session scoped in an xpages application

I'd wrote a session scoped managed bean to cache the sesion user specific info in a domino xpages application,just like the following codes: public class NBUserInfo { private String ...
wang deyong's user avatar
0 votes
1 answer
288 views

How to set a bean property of an injected CDI bean from the contains Bean?

I have a CDI Bean which is injected to another CDI bean, Bean1Controller: @ViewScoped public class bean1Controller { @Inject Bean2Controller bean2; // + setter and getter // here I ...
majdi's user avatar
  • 43
0 votes
1 answer
539 views

How to pass bean value to JavaScript before form submit

I am making webpage about ride sharing/selling bus tickets using JSF. On one particular page, logged users can publish their ad (offering or looking for ride). They should enter info like: ad title, ...
misty's user avatar
  • 123

1
2 3 4 5
20