aspose file tools
The moose likes JSF and the fly likes How to call the javascript method in  jsf while calling servlet? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JSF
Reply Bookmark "How to call the javascript method in  jsf while calling servlet? " Watch "How to call the javascript method in  jsf while calling servlet? " New topic
Author

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

jayaganesh marappan
Greenhorn

Joined: Apr 15, 2008
Posts: 5
<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
Saloon Keeper

Joined: Jun 25, 2001
Posts: 14491
    
    7

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.


Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: How to call the javascript method in jsf while calling servlet?
 
Similar Threads
command link
<verbatim>
MARQUEE componenet in JSF ???
Probem in javascript in a JSF when implementing tiles in it
How to use javascript in JSF