web service call not reached from javascript.

Post any questions you have about using the Verj.io Studio, including client and server-side programming with Javascript or FPL, and integration with databases, web services etc.

Moderators: Jon, Steve, Ian, Dave

xren
Ebase User
Posts: 272
Joined: Fri Dec 14, 2012 2:55 pm
Location: Ottawa

web service call not reached from javascript.

#1

Postby xren » Thu Nov 07, 2013 12:11 pm

Hi,

I have a web service backed by the integration service, which worked fine when I test it from the designer. However, it seems not working when I call it from javascript from a form.
It seems not triggered.

What the reason could be?

Thanks,
Xiaoli
0 x

xren
Ebase User
Posts: 272
Joined: Fri Dec 14, 2012 2:55 pm
Location: Ottawa

#2

Postby xren » Thu Nov 07, 2013 3:42 pm

I think it might be the same origin policy thing. But I could not figure out how to fix it now. I met this before and fixed it that time without detail log of the solution. :(
0 x

Jon
Moderator
Moderator
Posts: 1342
Joined: Wed Sep 12, 2007 12:49 pm

#3

Postby Jon » Thu Nov 07, 2013 4:33 pm

Xiaoli,

We get around this problem by getting the server to call the web service, not the client. This is done using executeFunction() in the client API that was introduced with Ebase V4.5. The client passes data to the server with executeFunction() which runs a script to call the web service, then returns the response to the client. We have used this successfully a few times.

I think there is an example of this in the samples folder "Writing and Calling Web Services" http://forum.ebasetech.com/forum/viewtopic.php?t=513.

Regards
Jon
0 x


Who is online

Users browsing this forum: No registered users and 8 guests