How to use predefined variables

Printing predefined variables:-

The current file is
/home/bhamad/public_html/infost440/assignments/assignment2/predefined.php

The name of the server is
bhamad.uwmsois.com

Viewing this page using
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36

How it works (Explanation)

To get information about the server or client quickly, PHP provides a set of predefined variables. It includes information about the current page's file, the server name, and the device name of the client.

Source Example for the work above

Example