How are scripts created in a computer

Simply put: what is a script?

In addition to common programs and applications, scripts also play an important role in information technology. In this article, we will explain what a script is and what it is typically used for.


1. Definition: What is a script?

In information technology, a script is a short sequence of commands that is executed by a specific program (e.g. a web browser or a server application). They are primarily used to automate processes on local computers (Windows or Mac), but are often used to generate websites or for configuration tasks within the IT infrastructure.

Intentional meaning: Scripts are mostly text documents, so you can edit them with a common text editor.

Scripts are mostly text documents that are written in a so-called script language. Therefore, you can usually write, open and edit with a common text editor (e.g. Notepad or TextEdit) without any problems.

2. Where are scripts used?

In contrast to classic programming languages, scripts are not compiled, but interpreted. This means that the source code is the same as the execution code. However, this has the disadvantage that a translation is necessary every time it is executed, which ultimately affects the speed.

Tip: Instructions for troubleshooting script errors in Internet Explorer can be found here.

The login on your computer or a website is almost always controlled by a script.

Therefore, scripts are usually not used for very computationally intensive tasks, but rather used as a supplement to the system languages. Depending on the type of script, these can, for example, be used very well under Windows as support for Visual Basic or DOS processes. For example, a script almost always controls the login on your computer or a website and the macros in your Office programs are typical examples of this.

On Mac computers, on the other hand, you are primarily responsible for automating tasks. Java scripts are generally valid and can be used to generate dynamic websites. In contrast to this, UNIX scripts are mostly used to record the inputs and outputs of a terminal.

3. Which script languages ​​are there?

There are now a number of different scripting languages. The most popular (and also most used) are undisputedly Perl (Practical Extraction and Report Language) and PHP (Hypertext Preprocessor), which are mainly used to create Internet applications.

Good to know: With Windows PowerShell, Microsoft itself offers a cross-platform framework consisting of a command line interpreter and the associated scripting language.

4. Sample script: Determine latency times with the help of Powershell

The following example script can be used to determine the exact latency times of individual pages or servers via ping. The Powershell command required for this is "Test-Connection".

$ servers = @ ("", "", "") $ loop = "10000" for ($ j = 0; $ j -lt $ loop; $ j ++) {Write-Progress -activity "Determine latency times. . . "-status" Already checked: $ j of $ loop "-percentComplete (($ i / $ loop) * 100) Get-Date | Out-File" c: \ temp \ datum.txt "-append for ($ i = 0; $ i -lt $ servers.length; $ i ++) {$ latency = ($ servers [$ i]), (Test-Connection -ComputerName $ servers [$ i] -Count 1 | measure-Object -Property ResponseTime -Average) .average $ latency | Out-File "c: \ temp \ result.txt" -append}

For a detailed explanation of scripts, see the following YouTube video:

44 ratings

Ø 4.70
Simply put: what is a script?
4.7544Loading ...