0 Replies Latest reply on Aug 8, 2012 11:18 PM by Vikas V

    Behaviour of h:commandLink

    Vikas V Newbie

      Hi,

       

      Am using JSF 1.2

       

      I have 2 h:commandLink in my page. A user has to fill in the details in the input text box (I have used h:inputText for this and all fields are mandatory), and click on "Submit". If a user dont wish to fill in any of these fields there is a link provided below Submit button for "Skipping this activitiy" . This skip link will redirect to some other page. Both Submit link and Skip link are h:commandLink. I cant use h:outputLink for Skip because when user clicks on Skip I want to call bean and do some business checks.

      Now, when a user doesn't fill in any of the details in the fields, but instead clicks on Skip link, the required=true attribute of h:inputText is getting fired. I want this to get fired only when user clicks on Submit without filling in any details and not when he clicks on Skip link.

      How to achieve this?

      Regards,