This week's book giveaway is in the OCPJP forum.
We're giving away four copies of OCA/OCP Java SE 7 Programmer I & II Study Guide and have Kathy Sierra & Bert Bates on-line!
See this thread for details.
The moose likes JSF and the fly likes Need help with JavaScript  and JSF Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Java » JSF
Bookmark "Need help with JavaScript  and JSF" Watch "Need help with JavaScript  and JSF" New topic
Author

Need help with JavaScript and JSF

abhilash nalla
Greenhorn

Joined: Nov 05, 2008
Posts: 5
I need help with following scenario:

I have a XML file wherein the parameters of different pop-up windows are stored(height,width,left,top).

Now I open a pop-up window from my JSF by calling a Javascript function.When I call that JS function, values are forwarded from XML file to the Javascript. There will be multiple pop-ups on a single page.

Now the User can change the position and size of the pop-ups and clicks a "Save settings" button on the Pop-up.When the user clicks, the new coordinates will be saved into the XMl so that whenever he opend that pop-up it opens in the new location with new coordinates.

Can you guys please help me out in this. How should I proceed ?

1. Should I use AJAX for this such that AJAX reads the coordinates from XML files and updates it ?

2. Or JSF reads the values from XML file using a Backing Bean and then forwards these values to Javascript. Similarily when I need to write values to XML, Javascript forwards these values to JSf and JSF calls the Bean which updates in XML.

Please help me out in this.

Abhilash
sujit suncert
Greenhorn

Joined: Nov 04, 2008
Posts: 6
You guessed it right. JSF with AJAX can be used to achieve this.


-sujit(Never lose hope)
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61448
    
  67

"sujit sun certified", please check your private messages for an important administrative matter.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Need help with JavaScript and JSF