JavaScript can be used for many purposes including shell scripting with Windows Script Host (WSH), monitoring and debugging HTTP requests with HTTPWatch, and programmatically interacting with the browser DOM and making HTTP requests with different browsers like Internet Explorer and Firefox. The document demonstrates how to use JavaScript with WSH, HTTPWatch, and the browser DOM to inspect and modify HTTP requests and the DOM structure.
39. var har = http.toHAR();!
har = eval('(' + har + ')');!
!
print(har.log.browser.name);!
print(har.log.browser.version);!
print('# requests: ');!
print(har.log.entries.length);!