Author Topic

Jorge estévez

Wednesday 07 May 2008 5:33:31 am

Comment49363

Hello, let me explain a bit further

I am using a Javascript object that builds a treeview, this treeview loads its branches (child nodes) dynamically using an XML file at the server using XMLHTTPRequest, there are two ways of doing this operation:

1. Passing the URL of the XML file with the structure of the branch that should be loaded
2. Reading the contents of the file and passing as a parameter "the XML string"

The implementation at our site allows us to generate once the URL has been given (e.g. www.mysite.com/index.php/content/view/xml/172) all of the Childs that belong to that node.

The problem:

As ez knows how to read the URL's generated by the system, but JS does not, we think it's a better idea to take into consideration the second option, so we would like to obtain a response chain with the XML needed and pass the information to the JS function. So we need to make a request, save the response in a variable and give this variable to the JS code.

In ez docs a native code is mentioned ezSOAPClient that suggest that it can be used to make requests and get responses to the server but I cannot find any hints that could give me an example on how to use it, I am quite sure this could be a solution but with no help at all I am kind of grounded.

Gaetano, The JS is already developed and I cannot build JSON templates. Your explanation about the custom http request could be a guide, but if defined, is the JS going to "get" the XML code of the page. I mean ez will certainly get that code, but is JS going to do the same? If you could give us more information so we can carry on it will be appreciated indeed.

thanks again, this is the only issue to end up our web site project.

I am going to post some parts of this message as a new question to see if I could get anwsers about the ezSOAPClient.

Diseño Web Cuba
Web Design Cuba
www.elfosdesign.com