Got a small issue. I have a commandLink element. I want to intercept the clicking of this with a javascript confirm box.
I can show the confirm box using the onClick event handler but I need to only perform the link's action if the confirm box returns true (if the OK button is clicked).
why don't u do it in faces-config.xml? u can link the page from there to go to another new page.
but if u really want to do it in javascript, u can first call a javascript function and then in the javascript function u do alert and also redirect. [ July 04, 2005: Message edited by: Jolie Lee ]
Jys<br /><a href="http://jy-s.com" target="_blank" rel="nofollow">http://jy-s.com</a><br /> <br />Trying my very best to learn java, please forgive me if i'm asking some really stupid questions.
I have a navigation rule in faces-config.xml - this works fine. I can also attach a JS confirmation to the command link, that pops up fine. What doesnt work is only firing the action on my command link if the user presses OK on the confirmation box
u can pass the message and link from ur bean to ur jsp page..
and in ur jsp page u can do something like this..
so when user clicks OK, it will go to the messageLink that u specify from ur bean.
hope this helps.
Jys<br /><a href="http://jy-s.com" target="_blank" rel="nofollow">http://jy-s.com</a><br /> <br />Trying my very best to learn java, please forgive me if i'm asking some really stupid questions.
Don't get me started about those stupid light bulbs.