• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to call the javascript method in jsf while calling servlet?

 
jayaganesh marappan
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
<hutputLink rendered="#{campaigncreator.campaign.type == 'DYNAMIC' and campaigncreator.updButtons}" value="../mtcservlet/previewdynamiccontent?dynamiccontent=#{campaigncreator.html}" target="_blank">
<f:verbatim>Preview Dynamic Campaign</f:verbatim>
</hutputLink>

Here instead of this #{campaigncreator.html} ,i want call this javascript method.like getHtml();
 
Tim Holloway
Bartender
Posts: 18418
60
Android Eclipse IDE Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You're probably better off using RichFaces. It provides a outputLink tag with better JavaScript support (actually, AJAX support), For simple stuff, just use the onclick attribute, however. The "value" property is for getting the data value, not dispatching logic.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!