code to call javascript from a managed bean