To use this website fully, you first need to accept the use of cookies. By agreeing to the use of cookies you consent to the use of functional cookies. For more information read this page.

Official ZPE/YASS documentationSystem variable

The system variable as it is known, was added in version 1.7.4 of ZPE/YASS and is designed to hold information about several things. More than anything, it is to avoid the over complication of adding several functions to perform the same thing.

The system variable is an associative array global variable that contains several values such as the number of processors available to the system, the line separator for the operating system, the current working directory, the document root, the script start time, the executable path, the operating system information and much more.

Using the system variable is easy:

//Will print the whole system variable

The output from this should be the standard style of output from an associative array, which matches the key to value pairs in an unordered set.

Using ZPE 1.7.5's beautify function, the display can be much cleaner and easier to read:

//Will print the whole system variable

The result would look more like:

SCRIPT_PATH => /zpe-exec
CWD => /Users/zpe
START_TIME => Thu Mar 28 12:35:52 GMT 2019
HOME_DIR => /Users/zpe
DOCUMENT_ROOT => /Users/zpe
EXEC_PATH => /Users/zpe/Programs/ZPE

There are no comments on this page.

New comment
Comments are sent via email to me.