Message from JavaScript discussions

June 2019

— I am sending Ajax request for different api through one Ajax request that for each api I have to use different calla back function

Message permanent page


I don't think you understand "multiple callbacks in one ajax request".
Because for that you can simply do:
$.get('', data => {callback1(); callback2(); callback3()})
But your second message sounds like you have two ajax calls all of a sudden... different API? one Ajax Request? IN THAT for each API (what is each? how many?) and then different callbacks.
So it sounds like you need nested callbacks.
So just do `$.get('api1', data => {$.get('api2'), data2 => {console.log(data,data2)}})
or if you want to run in parallel use Promise.all Meenu

— So what do you have: serial or parallel api calls?

— Like this


// Is the same as

— Exactly. This is not php :p

— Hi please has anyone use FASTSMS API before in PHP

if yes please help me config my on my server its not working

Message permanent page

— Guys , one doubt
I have a set of values in a dictionary
And I need to send these values into JavaScript to draw a pie chart.

The problem is I need assign values from the dictionary to different variables in JavaScript

Message permanent page

— Don't do that

— Just put them all in an object

— Guys help i cannot run a node js code on intelli j

— What you meant by?