Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

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

 
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: 18531
61
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.
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!