Question

I have an assignment to load the xml in the DHTMLX grid from a remote file. In this case an oracale db. I m stuck in the following code snippet:

gridname.loadXML("somefile.do?pageAction=somemethod"+"&somemethod2");

Any guru, Please tell me whats going on in the above code and what are basics i need to complete before i understand it? Thanks

Était-ce utile?

La solution

"gridname" is the name of a javascript component called dhtmlXGridObject which has been instanciated this way :

gridname = new dhtmlXGridObject('gridname');

You can found an exemple of loading such a grid with hard coded XML here : http://www.dhtmlx.com/docs/products/dhtmlxGrid/samples/12_initialization_loading/10_init_grid_xml.html

In your snippet, it shows that you are calling a Struts action (java controller) which will return you an XML file. You have to find a somefileAction.java source file and then read the appropriate method to know how this XML is produced.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top