Tips & Tutorials

Chrome Kiosk Mode On PC Android iOS Chrome OS (A Quick Tutorial)

Welcome to a quick tutorial on how to set Chrome into kiosk mode. Yes, there is a hidden gem called “kiosk mode” in Google Chrome that not many developers know of. It is but a very simple mechanism to set Chrome into full screen incognito and removes all navigation bars. That is, we can easily …

Chrome Kiosk Mode On PC Android iOS Chrome OS (A Quick Tutorial) Read More »

Javascript Fetch With GET Query Params (Quick Examples)

Welcome to a tutorial and example on how to send a Javascript fetch request with GET query parameters. New to the fetch API, and trying to pass in some query parameters? To send GET query parameters with Javascript fetch, simply create a new URL object and append the search parameters: var data = { “KEY” …

Javascript Fetch With GET Query Params (Quick Examples) Read More »

How To Get HTML Content With Javascript Fetch (Simple Example)

Welcome to a quick tutorial and example of how to get HTML content using the Javascript Fetch API. So you are wondering if fetch() can get HTML content just like XMLHttpRequest? Of course, we can. To get HTML content with the Javascript Fetch API, simply make a fetch() call to the script and return the …

How To Get HTML Content With Javascript Fetch (Simple Example) Read More »

Javascript Fetch With HTTP Basic Auth (Simple Example)

Welcome to a tutorial and example on how to do a Javascript Fetch request with HTTP basic auth. To perform Fetch with HTTP basic auth, simply include the authorization headers in the request. var credentials = btoa(“USER:PASSWORD”); var auth = { “Authorization” : `Basic ${credentials}` }; fetch(“http://site.com/protected/”, { headers : auth }); That covers the …

Javascript Fetch With HTTP Basic Auth (Simple Example) Read More »

How To Add Leading & Trailing Zeroes To Numbers In Javascript

Welcome to a short tutorial on how to add leading and trailing zeroes to numbers in Javascript. So you have some numbers that require padding of zeroes? The easy way to add leading or trailing zeroes in Javascript is to: Concatenate the number with a string of zeroes. var num = “000” + 123; var …

How To Add Leading & Trailing Zeroes To Numbers In Javascript Read More »