What is JavaScript? An Understandable Explanation

The question “What is JavaScript?” Can be answered with “One programming language”. We explain to you where JavaScript comes from, what it does, and why you should sometimes block JavaScript. JavaScript is a scripting language that is usually used in websites and is then executed by the visitor’s browser. Originally, in 1995, JavaScript was still called LiveScript and was primarily used to check a visitor’s form entries. It was developed by Netscape and was later used in all browsers.

Related Articles for the subject:

  1. What is HTML?
  2. What is CSS?

What is JavaScript and what is it used for?

What is this JavaScript I am always warned of? The possibilities of this language were expanded more and more so that meanwhile it has become a complex programming language with which almost everything is possible. JavaScript ensures that websites can be dynamically built and adapted to the user. Complex control queries can be programmed in JavaScript and linked to databases in order to check visitor input. Extensive browser games are written in JavaScript that is made so clever that they can hardly be distinguished from the original.

The best way to explain what JavaScript is is through examples. JavaScripts are inserted within the HTML code of a website and are then executed by the browser. That means: As long as a browser does not run JavaScript, the underlying action will not happen either. Usually, however, all browsers are set to execute any JavaScript found.

However, browser plugins like NoScript ensure that you can globally deactivate any JavaScript found on any website. Also, Adblocker blocks especially the advertisement scripts. Thus, you can download less from the web page and engage faster. On the other hand, many pages may not work anymore without Javascript. If the web site is built on Vue, React, or Angular and they don’t use Server Side Rendering (Javascript is being rendered on the server so that your device doesn’t have to render the same Javascript assets), you may see nothing.

What is JavaScript as a threat?

As mentioned at the beginning, JavaScript is no longer what it used to be. The harmless, small script language for data verification has blossomed into a full-fledged programming language. What is JavaScript can now also be answered with: A potential source of danger!

JavaScript can be used to make the browser load commands and content from other pages in the background. You look at a website and at the same time JavaScripts reload actions from other servers. What if the programmers reloaded something completely different? When they load a trojan that nestles in Windows?

That is exactly what happens again and again. You catch so-called drive-by infections on infected websites that you only have to visit once. The code can come in the mail program or as a link that you click on. And then it happened: the JavaScript exploited a not yet fixed security vulnerability in the browser to inject a Trojan into Windows. It reloads further malicious code and your PC is already under the control of any criminal subject. Once they are known, such scripts are blocked by good virus scanners. But until then you have to be careful yourself. For example, be careful where you visit or check the web site’s SSL Protocol or you can use safer browsers such as Firefox.

What are the Major Usage Purposes of Javascript

The syntax of JavaScript is similar to C descendants. Despite the name and syntactic similarity, JavaScript has little in common with Java. In JavaScript, inheritance is not supported by classes but by prototypes.

In the past, JavaScript was mainly used on the client-side. JavaScript or the ECMAScript implementations also enable server-side applications, for example, with the framework Node.js and as JScript or JScript .NET in an ASP or ASP.NET environment on Microsoft Internet Information Services. Other examples of server-side JavaScript programming are POW and Jaxer, which are based on the Mozilla JavaScript engine SpiderMonkey, V8CGI, which is based on the JavaScript implementation V8 and is integrated into the Apache HTTP Server, and QML, an expanded form of JavaScript for drawing surfaces and animations.

The language is also used as a scripting language for games and application programs, since the language core contains only a few objects and the interpreter required to execute scripts formulated in JavaScript can thus be kept relatively small.

In addition, JavaScript is used as a communication language in the MongoDB database and in microcontrollers.

Typical Areas for JavaScript Applications:

  • Dynamic manipulation of websites via the Document Object Model
  • Plausibility check (data validation) of form entries before the transfer to the server
  • Display of dialog boxes
  • Sending and receiving data without the browser having to reload the page (Ajax)
  • Suggest search terms as you type
  • Banners or tickers
  • Disguise email addresses to combat spam
  • Switch multiple frames at once or detach the page from the frameset
  • Read and write access to cookies and the web storage within the browser

Typical Abusing Areas via Javascript Applications:

  • Disguise Internet addresses that a link points to
  • Deactivate the context menu to make it more difficult for images or the entire page to be saved
  • Deactivate the copy function to make it more difficult for texts or images to be copied
  • Unsolicited (advertising) pop-ups or pop-unders or successive dialog boxes that hinder the user
  • Unintentional closing of the browser window
  • Unwanted resizing of the browser window
  • Low-barrier websites are characterized by the fact that they can be used as unrestrictedly as possible even when JavaScript is switched off. Deactivated JavaScript partially limits the usability of a website.
  • Measures that allow a user to be recognized when the user visits a website later (see anonymity on the Internet)
  • For vulnerable web applications, JavaScript can also be misused by third parties, for example via XSS (code injection).

Conclusion: What is JavaScript now?

What is JavaScript really? JavaScript is a tool, a programming language. You can use it to program viruses or great browser games. Many websites, such as eBay, are unthinkable without JavaScript. But if someone finds and exploits a vulnerability, JavaScript can cause financial damage from data theft. JavaScript enables detailed visitor statistics with which the website can be improved. But certain scripts also track you through the Internet and log your preferences and surf sessions. It was recently announced that the anonymization network Tor could be attacked by faulty browsers and JavaScript.

So JavaScript is always what is made of it. And for you, it is something that you should at least always keep an eye on. Not every JavaScript is necessary for you and often you should deactivate some JavaScripts. But generally, none of you would want an Internet without JavaScript.

Javascript SEO is also another topic for Holistic SEOs. It is also related to the Page Speed and User Experience. We will examine the Javascript deeper with time in Holistic SEO Vision.

Koray Tuğberk GÜBÜR

Leave a Comment

What is JavaScript? An Understandable Explanation

by Koray Tuğberk GÜBÜR time to read: 5 min
0