Term of the Moment

CarPlay


Look Up Another Term


Redirected from: escape command

Definition: escape code


A text command preceded either by the escape (Esc) character (ASCII 27) or some other symbol such as an ampersand (see below) or backslash (see string literal). The escape code signals the device to execute the text command rather than print or display the text characters. For example, the escape character (ASCII 27) followed by &l10, sets the LaserJet printer to landscape mode. See ASCII chart.

Just the Opposite: Render - Don't Execute
Escape codes are also used to achieve the exact opposite effect: causing a command to be displayed or printed rather than executed. For example, while within an environment that renders HTML, it may be necessary to display HTML tags intact for instructional purposes without executing them. In such cases, an ampersand (&) is used as the escape character. When followed by lt (less than) or gt (greater than) plus a semicolon, it is rendered as < and > text symbols rather than treated as a tag delimiter. See ampersand codes.