1 Reply Latest reply on Jun 28, 2007 7:11 PM by Sergey Smirnov

    Calling a JavaScript func to play a sound IF value in manage

    Mike Maurer Newbie

      I have a use case where I need to play a warning sound if user submits an invalid product number. I can use the SoundManager2 JavaScript api to play the sound. But how can I call the JavaScript function based on a value in my managed bean? What I want to do is attach an action to a command button that calls a method on the backing bean to validate the product number. If the validation fails then I need to call the JavaScript function that plays the warning sound. Sounds simple enough, but how to bridge the apparent gap beteween client side JavaScript and server side bean? Maybe a whole different approach would work better. Any ideas?