Javascript Fetch API Primer Tutorial

Javascript Fetch API Primer Tutorial

Javascript Fetch API Primer Tutorial

More and more, around here, recently, constructing web applications using PHP/HTML/Javascript we have added to a list of “URL response tools”, adding to an “off the top of our head” list of (just the HTML and Javascript “client side”) navigational ideas …

  • location.href='[URL]’; #same webpage, but reload, perhaps with different content
  • document.location.reload(); #same webpage, same initial content, cache may come into play
  • Refresh (eg. every 5 seconds) via head element subelement like <meta http-equiv=”refresh” content=”5″> #same webpage, same initial content, cache may come into play
  • window.open(‘[URL]’,’_blank’); #new webpage
  • window.open(‘[URL]’,’_self’); #same webpage, perhaps with different content
  • HTML form action='[URL]’ target=_blank #new webpage
  • HTML form action='[URL]’ target=_self #same webpage, but reload, perhaps with different content
  • location.hash=’#[stuff]’; #same webpage, no reload, detect, analyze and act on [stuff]
  • location.href=’#[stuff]’; #same webpage, no reload, detect, analyze and act on [stuff]
  • Ajax open then send([perhaps FormData object]); #same webpage, extract content … we’ve recently started using another way to extract information but stay on the same webpage as …
  • Fetch API Javascript “fetch” command #same webpage, extract content

… we’ve used to, so far …

… but who knows what the future brings?!

If this was interesting you may be interested in this too.

This entry was posted in eLearning, Event-Driven Programming, Tutorials and tagged , , , , , , , , , , , . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *