Hey all, in this asynchronous JavaScript tutorial, I’ll be showing you how we can make http / ajax requests using vanilla javascript, as well as using the $.get() method in jquery.
—– COURSE LINKS:
+ Repo – https://github.com/iamshaunjp/css-animations-playlist
+ Brackets editor – https://brackets.io/
———————————————————————————————
You can find more front-end development tutorials on CSS, HTML, JavaScript, jQuery, WordPress & more on the channel homepage…
SUBSCRIBE TO CHANNEL – https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg?sub_confirmation=1
========== JavaScript for Beginners Playlist ==========
============ CSS for Beginners Playlist =============
============== The Net Ninja =====================
For more front-end development tutorials & to black-belt your coding skills, head over to – https://www.youtube.com/channel/UCW5YeuERMmlnqo4oq8vwUpg or http://thenetninja.co.uk
================== Social Links ==================
Twitter – @TheNetNinja – https://twitter.com/thenetninjauk
Original source
39 responses to “Asynchronous JavaScript #2 – AJAX Requests”
I'm following your tutorials bro , your the best haha . can you make some tutorials about php & laravel . thanks a lot …
This is awesome 🙂 For the first time i understand what's actually going on !
This series is probably the best explanation of async I've come across. Thank you so much!
Dude.. you running a university here lol. Best tutorials I have ever come across … I am using to learn new skills so I can build my startup …. I will always give credits to you man
the course link is actually not correct. it goes to some different stuff.
You use Atom, not Brackes as you say in the description.
You know the best part is that I never really understood the XMLHttpRequest thing and always just did it with jQuery until today, I have no idea how you explain things so damn well. Thank you!
By far the best explanation on the planet. Thanks a ton .
Is it redundant to check readyState == 4 && status == 200? Could a status ever be 200 if the request was not completed?
subscribed! your content is great. Please keep up the good work!
Excellent! Thanks!
What a great explanation! Thanks dude 😇
Thank you! +1
Even thought I think I have a good idea of how async code works, I love watching the video's that you guys put out. They are really great!
awesome. looking forward for more advanced topics on JS
This is superb work, thank you. Hope you're being rewarded for your efforts.
I like the way you talk and explain as you code! Something so simple as "If readystate is equal to 4"… has fixed the meaning of == meaning equal in my mind, which I could not get used to before!
Thank you again,
Paul
I can only give you one thumbs up :(. Please keep making awesome tutorials like this
Great tutorial as far as the javascript goes, but I would like there to be a bit more information on how to set up the dev environment and actually run the code. I am using Atom and have the atom-live-server plugin installed, but it just opens up a browser tab listing the source code. It doesn't run anything. I know how to embed a script in an html page but the impression given by this tutorial is that you can just run the JavaScript as is.
Really well done, thanks!
Love the tutorials. Information is always perfectly presented for any level of coder. Any plans on a object oriented php, or maybe just php for beginners tutorial?
Really you are superb man…i learn a lot of things…..
Thanks! The tutorial is very helpful;) By the way, is there a way to save a chunk of data from the request to pass it to a different API? I created a function that connects to the Google maps API but I failed to pass the data I got to connect to the Dark Sky Weather API. The function returns "undefined" every time I try to store the data from Google in a variable.
Good tutorial , well done. My ajax request is not going until the step 4. It looks it's stucked at 3.What could be the reason of it?
Beautifully explained. Thank you!
what the program name
great work thanks
you're my god damn hero
Hello Ninja. I heartedly enjoyed this video. Might I say, it's one of the most pellucid lessons on javascript ajax requests on YouTube. I especially relished the lesson being first given in plain vanilla javascript before moving forth to the library. Thank you.
I've never imagined that ajax is that so easy !!!
Thank you ninjaaa
This series is probably the best explanation of async I've come across. Thanks so much.
great video! The logging to the console part is new to me, I tried to get chrome to show me what it was showing you. I couldnt seem to, how are you doing that?
hello , great course, i have a question
how can i create a function If there is 5 or more ongoing requests, you have to wait until one
of them is completed then you can process next request.
When the response code is not 200, you need to retry 3 times. If the response code after
retrying 3 times is still not 200 then the error function should be executed.
can I get just a particular fragment of JSON file with JS or it always returns full text of JSON file and I need PHP to do this?
Hi what exactly is JSON ? Did you say something about it before ?
Holy Beard of Zeus thank you so much for this! You just alleviated some immense frustration.
When are you using JSON.stringify() vs. JSON.parse()?
awesome!! extremely glad to have found this channel!
jQuery + AJAX version of these ever coming? Specifically just using the $.ajax() method / object to make get and post request successfully? Pretty familiar with get but post is still sort of foreign as you need a backend(server) set up to handle them I believe. Some tuts where you set up a quick and dirty server using express and node (because keep everything javascript why not 🙂 lol) would be great. Anyways good stuff man. I started with with your node series. Then did the vanilla js and jQuery series for some review / refresher and you make the material very easy to digest. I'm subscribed!
This guy is simply awesome
Really easy to understand.. Thanks guy!