On Mon, Mar 8, 2010 at 1:11 PM, Zoran Jeremic <jeremic1...@yahoo.com> wrote: > Hi, > >>Does it matter how your JavaScript communicates with the server >>- does it just need to make request-response style calls to the server >>so the protocols can be handled and hidden by Tuscany, or do you need >>control over that, for example to use jsonp or jsonrpc or a particular >>toolkit like Dojo or JQuery? > > I'm not sure in the moment if I will have some specific requests regarding > the protocols. I think not, but I need to exchange json like data (used to > generate jsTree component) between server and client. > I have already tried to use Dojo, as it looks like nice solution to my > problem, but I couldn't make it works. I used provided examples, but I don't > know if I have missed something. Here is a code: > > <script type="text/javascript"> > var djConfig = { > parseOnLoad: true, > baseRelativePath: "dojo", > isDebug: true, > debugContainerId: "dojoDebug" > }; > djConfig.usePlainJson=true ; > </script> > > <script type="text/javascript" src="js/dojo/dojo.js"></script> > > <script type="text/javascript"> > dojo.require("dojo.parser"); > > dojo.require("dojo.rpc.JsonService"); > </script> > > ... > > var smd=new > dojo.rpc.JsonService("http://ZoranPC:8080/CreateLearningGoalsService?smd"); > var > competences=smd.getAvailableCompetences().addCallback(contentCallBack); > > > I always get error in Firebug > > smd.getAvailableCompetences is not a function. > > Did I miss something here. I didn't add anything Dojo related to the server. > Do I need to use something there in other to connect client with Web > Services. > > Zoran > ________________________________
Could you please provide your composite file where you define/configure your service -- Luciano Resende http://people.apache.org/~lresende http://twitter.com/lresende1975 http://lresende.blogspot.com/