aspose file tools*
The moose likes JSF and the fly likes rendering XHTML components from ajax+Jquery Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » JSF
Bookmark "rendering XHTML components from ajax+Jquery" Watch "rendering XHTML components from ajax+Jquery" New topic
Author

rendering XHTML components from ajax+Jquery

senthil selva
Greenhorn

Joined: Mar 18, 2013
Posts: 4
Hi frnds...
i need to update a "div" container with a "xhtml" page, from the page where the "div" container resides...
Below are my codes...

updateDiv.xhtml




myjs.js


divContent.xhtml





the button click on "updateDiv.xhtml" calls the javascript function "updateDivContent()" and it inturn it calls the "divContent.xhtml" ..No probs with the ajax call..
the problem is with the rendering of "divContent.xhtml" 's "h:inputText" inside "updateDiv" div from "updateDiv.xhtml" , which does not render, it just gives out the "h:inputText" component and not the basic html component like "<input type="text" ..>"

can any one please help me in rendering the XHTML component ....
thanks in advance...
senthil selva
Greenhorn

Joined: Mar 18, 2013
Posts: 4
I solved this problem.....
the problem here is with the javascript url

myjs.js



i changed divContent.xhtml into divContent.jsf
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 15641
    
  15

senthil selva wrote:
i changed divContent.xhtml into divContent.jsf


"divContent.xhtml" is a resource name. Resources are not directly visible to clients.

"divContent.jsf" is a URL name. When a client submits a URL request to the server, the server dissects the URL string and routes the request to the appropriate URL handler. Which, in this particular case is the FacesServlet, which in turn examines the URL and hands it off to the Facelets resource resolver, which decodes the URL path into its corresponding resource path(s). So the divContent.xhtml resource is used by JSF to construct the response for a request for the divContent.jsf URL.

Customer surveys are for companies who didn't pay proper attention to begin with.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: rendering XHTML components from ajax+Jquery
 
Similar Threads
JSF: Jscolor stops working after first postback of fresh deploy
problem with new user
JSF 2.0 Login
What does "Content is being hidden from the validator based on namespace filtering" mean?
CSS in JSF