]> granicus.if.org Git - php/commitdiff
First step - abrief version.
authorMarcus Boerger <helly@php.net>
Wed, 5 Feb 2003 00:12:46 +0000 (00:12 +0000)
committerMarcus Boerger <helly@php.net>
Wed, 5 Feb 2003 00:12:46 +0000 (00:12 +0000)
@Added man page for CLI version of PHP. (marcus)
# I was also thinking about an author section with
# The PHP Group, Edin Kadribasic, Marcus Boerger, Rasmus Lerdorf,
# Stig Bakken and Zeev Suraski beeing mentioned. Group of corse and
# the rest is listed in php_cli.c.

sapi/cli/php.1 [new file with mode: 0644]

diff --git a/sapi/cli/php.1 b/sapi/cli/php.1
new file mode 100644 (file)
index 0000000..c270bf0
--- /dev/null
@@ -0,0 +1,215 @@
+./"    +----------------------------------------------------------------------+
+./"    | PHP Version 4                                                        |
+./"    +----------------------------------------------------------------------+
+./"    | Copyright (c) 1997-2003 The PHP Group                                |
+./"    +----------------------------------------------------------------------+
+./"    | This source file is subject to version 2.02 of the PHP license,      |
+./"    | that is bundled with this package in the file LICENSE, and is        |
+./"    | available at through the world-wide-web at                           |
+./"    | http://www.php.net/license/2_02.txt.                                 |
+./"    | If you did not receive a copy of the PHP license and are unable to   |
+./"    | obtain it through the world-wide-web, please send a note to          |
+./"    | license@php.net so we can mail you a copy immediately.               |
+./"    +----------------------------------------------------------------------+
+./"    | Author: Marcus Boerger <helly@php.net>                               |
+./"    +----------------------------------------------------------------------+
+./" 
+./" $Id$
+./" 
+.TH PHP 1
+.SH NAME
+.B php
+Command Line Interface 'CLI'
+.SH SYNOPSIS
+.B php
+[options] [
+.B -f
+]
+.IR file
+[[--] 
+.IR args...
+]
+.LP
+.B php
+[options] 
+.B -r 
+.IR code
+[[--]
+.IR args...
+]
+.LP
+.B php
+[options] [-B 
+.IR code
+] 
+.B -R 
+.IR code
+[-E 
+.IR code
+] [[--]
+.IR args...
+]
+.LP
+.B php
+[options] [-B 
+.IR code
+]
+.B -F 
+.IR file
+[-E 
+.IR code
+] [[--]
+.IR args...
+]
+.LP
+.B php
+[options] -- [
+.IR args...
+]
+.LP
+.SH DESCRIPTION
+You can parse and execute files by using parameter -f followed by the name of the 
+.IR file 
+to be executed.
+.LP
+Using parameter -r you can directly execute
+.B PHP 
+.IR code 
+simply as you would do inside a 
+.B php 
+file when using the 
+.B eval() 
+function.
+.LP
+It is also possible to process the standard input line by line using either
+the parameter -R or -F. In this mode each separate input line causes the
+.IR code 
+specified by -R or the 
+.IR file
+specified by -F to be executed.
+You can access the input line by \fB$argn\fP. While processing the input lines
+.B $argi 
+contains the number of the actual line being processed. Further more
+the paramters -B and -E can be used to execute 
+.IR code
+(see -r) before and
+after input line processing respectively.
+.LP
+If none of -r -f -B -R -F or -E is present but a single parameter is
+given then this is taken as the filename to process (same as with -f). If
+no parameter is present then the standard input is read and executed.
+.SH OPTIONS
+.TP 15
+.B -a
+Run interactively
+.TP
+.B -c path|file 
+Look for 
+.B php.ini 
+file in this directory
+.TP
+.B -n
+No 
+.B php.ini 
+file will be used
+.TP
+.B -d foo[=bar]
+Define INI entry 
+.IR foo 
+with value
+.IR bar
+.TP
+.B -e
+Generate extended information for debugger/profiler
+.TP
+.B -f file
+Parse and execute 
+.IR file
+.TP
+.B -h
+This help
+.TP
+.B -i
+.B PHP
+information
+.TP
+.B -l
+Syntax check only (lint)
+.TP
+.B -m
+Show compiled in modules
+.TP
+.B -r code
+Run 
+.B PHP 
+.IR code
+without using script tags
+.B '<?..?>'
+.TP
+.B -B code
+Run 
+.B PHP 
+.IR code
+before processing input lines
+.TP
+.B -R code
+Run 
+.B PHP 
+.IR code
+for every input line
+.TP
+.B -F file
+Parse and execute 
+.IR file
+for every input line
+.TP
+.B -E code
+Run 
+.B PHP 
+.IR code
+after processing all input lines
+.TP
+.B -s
+Display colour syntax highlighted source
+.TP
+.B -v
+Version number
+.TP
+.B -w
+Display source with stripped comments and whitespace
+.TP
+.B -z file
+Load Zend extension 
+.IR file
+.TP
+.IR args...
+Arguments passed to script. Use 
+.B '--'
+.IR args 
+when first argument starts with 
+.B '-'
+or script is read from stdin
+.SH FILES
+.TP 15
+.B php-cli.ini
+The configuration file for the CLI version of 
+.B PHP.
+.TP
+.B php.ini
+The standard configuration file will only be used when 
+.B php-cli.ini
+cannot not be found.
+.SH COPYRIGHT
+Copyright (c) 1997-2003 The PHP Group
+.LP
+This source file is subject to version 2.02 of the 
+.B PHP 
+license,
+that is bundled with this package in the file LICENSE, and is
+available at through the world-wide-web at
+.BR
+.B http://www.php.net/license/2_02.txt.
+If you did not receive a copy of the PHP license and are unable to
+obtain it through the world-wide-web, please send a note to
+.B license@php.net 
+so we can mail you a copy immediately.