Install the complete package with local command reference and every published mode.
install phpphpeval and file forms.
Diagnostics are the default; execution is not. Use the short summary or filtered phpinfo to understand the hosting environment, and move to
php [info|version|modules|eval|file] ...phpshow a concise
php info [query] [options]show structured phpinfo data and optionally filter rows
php versionshow
php modules [filter]show loaded
php eval <code>execute inline
php file <path>execute one
-gphpinfo general section
-cphpinfo configuration section
-mphpinfo modules section
-ephpinfo environment section
-vphpinfo variables section
-Cphpinfo credits section
-lphpinfo license section
-aall phpinfo sections
The bare
sandbox: the code runs with the
A compact summary, extension lookup, section filters and two explicit execution forms are demonstrated below. The shown results are fixed sandbox examples, not a live reading of your server.
Run the prepared examples directly on the page. Their results are prebuilt and shown in the browser; no terminal command is executed on the server.
Install the current compatible version. Choose Base for the complete feature set or Minimum for the reduced package; use upgrade to update a module that is already installed.
Base and Minimum are two packages of the same current module release, not separate command versions.
Install the complete package with local command reference and every published mode.
install phpInstall the reduced package. Local reference is omitted;
install php -mInstall exactly this published version.
install php -v 1.2.2Ask upgrade to check compatibility and replace the installed block only when needed.
upgrade phpRemove the extension block while leaving the core and unrelated modules intact.
install php -uExamples are copyable command lines, not actions executed by this website. Review paths, permissions and destructive flags before running them on a real project.
phpPHP 8.x
SAPI fpm-fcgi
OS Linux
Binary /usr/bin/php
Zend 4.x
Config /etc/php.ini
Modules 42php versionPHP 8.x
SAPI fpm-fcgi
OS Linux
Binary /usr/bin/php
Zend 4.xphp modulesCore curl json openssl
date dom mbstring sessionphp modules jsonjsonphp info memory -c[Core]
memory_limit 512Mphp info php -g[PHP]
PHP Version 8.xphp info json -m[json]
JSON support enabled
json version 1.xphp info path -e[Environment]
PATH /usr/local/bin:/usr/binphp info memory -vNo phpinfo matchesphp info -C[PHP Credits]
PHP Group The PHP Groupphp info -l[PHP License]
PHP License version 3.01php info memory -a[Core]
memory_limit 512Mphp eval "echo 2 + 3;"5php file \sandbox\scripts\php-demo.php{"project":"lil-sandbox","sum":5}php modules missing_extension(none)php file \sandbox\missing.phpPHP file not foundphp eval "exit;"PHP exit is not allowedsandbox/src/index.phpThe example uses a file or directory from the protected /sandbox/ documentation workspace.
<?php
declare(strict_types=1);
require_once __DIR__.'/Calculator.php';
header('Content-Type: application/json; charset=utf-8');
echo json_encode([
'project' => 'lil-sandbox',
'sum' => Calculator::add(2, 3),
], JSON_PRETTY_PRINT | JSON_UNESCAPED_SLASHES)."\n";
Removes layout-specific wording and keeps phpinfo section flags concise.