Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8418399
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T02:19:03+00:00 2026-06-10T02:19:03+00:00

I made following jsf page. In my Managed Bean i want evaluate the input,

  • 0

I made following jsf page. In my Managed Bean i want evaluate the input,
but i dont get the values.

If i press my commandLink i dont get any values. when i use a commandButton it works:

<?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:ui="http://java.sun.com/jsf/facelets"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:f="http://java.sun.com/jsf/core">

<ui:composition template="../templates/common.xhtml">
    <ui:define name="pageTitle">Test</ui:define>
    <ui:define name="pageHeader">Test</ui:define>
    <ui:define name="body">
        <h:panelGroup id="messagePanel" layout="block">
            <h:messages errorStyle="color: red" infoStyle="color: green"
                layout="table" />
        </h:panelGroup>
        <h:form>
            <h:outputLabel value="#{bundle.SearchAdressLabel_name}"
                for="axname" />
             <h:inputText id="axname"
                    value="#tbaxController.name}"
                    title="#{bundle.SearchAdressTitle_name}" />
                     </h:panelGrid>
            <br />
            <br />
            <h:commandButton id="submit" value="#{bundle.SearchAdressLabel_cmdsearch}"  action="#{tbaxController.prepareList}">
        </h:commandButton>

            <h:commandLink action="#{tbaxController.prepareList}"
                value="#{bundle.SearchAdressLabel_cmdsearch}" immediate="true" />  
            <br />
            <br />
            <h:commandLink value="#{bundle.SearchAdressLabel_cmdclear}"
                type="reset" />
        </h:form>
    </ui:define>
</ui:composition>
</html>

Here is a part of my MB:

@ManagedBean(name = "tbaxController")
@SessionScoped
public class tbaxController implements Serializable {

    private static final long serialVersionUID = 1L;
    private static final org.apache.log4j.Logger logger = org.apache.log4j.Logger
            .getLogger(tbaxController.class);

    private Tbax current;
    private DataModel items = null;
    @EJB
    private TbaxFacade ejbFacade;
    private PaginationHelper pagination;
    private int selectedItemIndex;

    private String name;


    public tbaxController() {
    }

    public String getname() {
        // Get the field
        return searchAxart;
    }

    public void setname(String oname) {
        // Set the field this.searchAxart
        this.name = oname.trim();
    }

    ...

    public String prepareList() {
        logger.info("prepareList:" + name); **//null with commandLink!
        recreateModel();
        return "ADList";
    }

     ...

Why does my prepareList method doesn’t get any values with a commandLink?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T02:19:04+00:00Added an answer on June 10, 2026 at 2:19 am

    The immediate="true" makes jsf to step over the process validation and update model phases. It jump directly to invoke application phase. That’s why you don’t get any values on the model. Try removing it and see what happens.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm using JSF 2.0 with GlassFish 3.0. I have the following Managed Bean: @ManagedBean
I get FC when running but it compiles. NOTE: Changes have been made following
I made a jsf project and have the following example from http://docs.openlayers.org/library/introduction.html but as
I've made following protection for my variables: $ad_title=htmlentities($ad_title); $ad_title=mysql_real_escape_string($ad_title); $ad_title=stripslashes($ad_title); But every time I
I have made the following regexp for extracting robots links: re.compile(r/\S+(?:\/+)) And i get
I need to validate phone number in PHP. I have made following regex, but
I made the following function to get the number of seconds from a time
I made the following code that works with the Google Tasks API but it
I want a route something like this: MyController/Action/categoryid/productid So I made the following in
I made the following website: www.appliedintelligentmarketing.com It works fine in all browsers but I've

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.