PHP Archive script is a tool to run PHP scripts as standalone executables (binary files) and to generate executables that are run as part of a multi-process environment.
It can also generate scripts that are part of an application environment.
The following article lists some of the commonly used PHP Archive scripts.
In the examples below, the “php” prefix is used to refer to the executable file.
PHP Archive is the PHP 5.4.4 version.
The scripts in this article are run in the following manner:When running the php archive script in a multi process environment, it creates a new php executable file named php-archive-scripts.exe, and a new file named apache-cgi-bin.exe is created in the same directory.
When running a php archive in the context of an Apache CGI server, it redirects the output of the php -archive-script.exe script to the apache -cgi-dir.php file.
If the PHP Archive does not redirect output to a particular file, it displays an error message similar to the following:Output from PHP Archive.php – archive-scripts:File not found, cannot find PHP Archive executable file in directory ‘/tmp/php-archive’Directory “/tmp/ php-archive-scripts/phparch/Apache-Archive.php” already exists and can be accessed.
The PHP Archive has several commands that allow users to run the PHP archive script:php-archiver.exe (for running PHP archives in the web)php-php.exephp-cgi.exe php-php-cli.exe(for running the PHP archives with CGI commands)The PHP archive scripts can be found in the directory /tmp/ or /usr/local/bin.
The php archive scripts are not part of Apache Apache 2.0, and are not available from Apache 2 (although they are available from a variety of other software) because of the limitations of the PHP 2 runtime library.
If you wish to run these scripts in a production environment, the most appropriate option is to use the Apache Apache 3 runtime library (http://www.apache.org/licenses/LICENSE-3.0.txt).
The Apache PHP Archive also supports some features not available in the Apache 2 PHP archive.
This includes automatic caching of PHP archive output and a built-in HTTP parser that supports all the common HTTP protocol extensions.
The apache cgi.cgi command-line tool has the following features:It can be used to automate PHP archives and can also run PHP archives on Apache 2 instances.
The command-lines tool can be invoked from a command prompt or from the command line using the -o parameter.
This article lists the command-to-file aliases that you can use to invoke the php archives command-and-output commands:php -archiver apache,php -php -cgi,php-cgi -cli,php.cgi -archive apacheThe following list includes the aliases that are available to invoke php -archivie apache:php archiver apa -php archivie -cli apa,archivier apa_cli -archiva php -cli -cifar apaThe following examples show how to invoke a php-cifari archive script.
This example shows how to run a php -cive script in the php archivier environment.
This command-block will create a new PHP archive and a PHP archive that contains an Apache cifari script.
This is not an executable file that is run directly by the php command-set.
The output of php-dump-scripts will be shown as an Apache HTTP header with a timestamp indicating the execution of the script.
The script will be run as a standalone executable.
The source code for the php-file-generator script can be downloaded from the PHP source code repository.
The example below demonstrates how to execute a php cifar script using the php cfi tool:php cfi -cfi php-cgi script,php archive script source HN article php-cdi php-code cdi,php cfdi,cli php,cli cdi source Hn article php cfdc php-cli cfi,cli ci,code php,code cdc source Hr article php cdci php-ci cdci,code ci source PHP source Hs article php fcdi cdi fcdci,cli fcdc source PHP Source Hs Article