JSON APIs and AJAX - Ahmed-Ayman/My-2017-Vacation GitHub Wiki

  • API -> Application Programming Interfaces: tools that computers use to communicate with one another..
  • JQUERY's function
//only when the code inside a page is loaded.
 $(document).ready(function() {
  });
//we can set event handler
 $('#element').on('click',function(){
  });

CallBack functions(callback pattern)

  • higher level funciton ...passed to another function.

the callback function os called (or executed) inside any otherFunction

$("#btn_1").click(function() {
  alert("Btn 1 Clicked");
});

http://javascriptissexy.com/understand-javascript-callback-functions-and-use-them#How_Callback_Functions_Work