1

I have a web page in jsp extension , which is built using jsf. There are command links for some user ids, i.e. every user id is a command link. When a user id is clicked, it goes to another page, where some action can be done.

<h:commandLink value="#{user.userId}" rendered="#{bean.myName == 'ID1'}"  action="#{bean.userIdHasBeenSelected}" immediate="true"/>

Now if the action returns a string called "notDone", i want to show an alert pop up in the jsp and the page will not be navigated and will remain in the same page. But , if the action returns the afore mentioned string , the page will just be not navigated..it will not be reloaded or refreshed..then how can i use window.onload here ?

If not window.onload , then is there any other way of doing it ? One point to be remembered is that, the action is evaluated at java side.

Any suggestions will be deeply appreciated.

Aritz
  • 30,971
  • 16
  • 136
  • 217
The Dark Knight
  • 5,455
  • 11
  • 54
  • 95

0 Answers0