Manual Pages for UNIX Darwin command on man php
MyWebUniversity

Manual Pages for UNIX Darwin command on man php

PHP(1) Scripting Language PHP(1)

NAME

php - PHP Command Line Interface 'CLI'

SYNOPSIS

pphhpp [options] [ -ff ]] file [[-] args...]

pphhpp [options] -rr code [[-] args...]

pphhpp [options] - [ args...]

DESCRIPTION

PPHHPP is a widely-used general-purpose scripting language that is espe-

cially suited for Web development and can be embedded into HTML. This is the command line interface that enables you to do the following:

You can parse and execute files by using parameter -f followed by the

name of the file to be executed.

Using parameter -r you can directly execute PHP code simply as you

would do inside a .php file when using the eevvaall(()) function.

If none of -r or -f is present but a single parameter is given then

this parameter is taken as the filename to parse and execute (same as

with -f). If no parameter is present then the standard input is read

and executed. OOPPTTIIOONNSS

-aa Run interactively

-cc path||file Look for pphhpp..iinnii file in the directory path or use the

specified file

-nn No pphhpp..iinnii file will be used

-dd foo[[==bar]] Define INI entry foo with value bar

-ee Generate extended information for debugger/profiler

-ff file Parse and execute file

-hh This help

-ii PHP information and configuration

-ll Syntax check only (lint)

-mm Show compiled in modules

-rr code Run PHP code without using script tags ''<>''

-ss Display colour syntax highlighted source

-vv Version number

-ww Display source with stripped comments and whitespace

-zz file Load Zend extension file

args... Arguments passed to script. Use ''--'' args when first

argument starts with ''-'' or script is read from stdin

FILES

pphhpp-ccllii..iinnii The configuration file for the CLI version of PHP.

pphhpp..iinnii The standard configuration file will only be used when

pphhpp-ccllii..iinnii cannot not be found.

EEXXAAMMPPLLEESS

php -r 'echo "Hello World\n";'

This command simply writes the text "Hello World" to standard out.

php -r 'printr(gdinfo());'

This shows the configuration of your gd extension. You can use this to easily check which imag formats you can use. If you have

any dynamic modules you may want to use the same ini file that php

uses when executed from your webserver. There are more extensions which have such a function. For dba use:

php -r 'printr(dbahandlers(1));'

TTIIPPSS

You can use a shebang line to automatically invoke php from scripts.

Only the CLI version of PHP will ignore such a first line as shown below:

#!/bin/php

// your script ?>

SEE ALSO

For a more or less complete description of PHP look here: hhttttpp::////wwwwww..pphhpp..nneett//mmaannuuaall// A nice introduction to PHP by Stig Bakken can be found here: hhttttpp::////wwwwww..zzeenndd..ccoomm//zzeenndd//aarrtt//iinnttrroo..pphhpp

BUGS

You can view the list of known bugs or report any new bug you found here: hhttttpp::////bbuuggss..pphhpp..nneett AUTHORS

The PHP Group: Thies C. Arntzen, Stig Bakken, Andi Gutmans, Rasmus Ler-

dorf, Sam Ruby, Sascha Schumann, Zeev Suraski, Jim Winstead, Andrei Zmievski. Additional work for the CLI sapi was done by Edin Kadribasic and Marcus Boerger. A List of active developers can be found here: hhttttpp::////wwwwww..pphhpp..nneett//ccrreeddiittss..pphhpp And last but not least PHP was developed with the help of a huge amount of contributors all around the world. VVEERRSSIIOONN IINNFFOORRMMAATTIIOONN This manpage describes pphhpp, version 4.4.9. COPYRIGHT

Copyright (C) 1997-2008 The PHP Group

This source file is subject to version 3.01 of the PHP license, that is bundled with this package in the file LICENSE, and is available through

the world-wide-web at the following url:

hhttttpp::////wwwwww..pphhpp..nneett//lliicceennssee//330011..ttxxtt 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

lliicceennssee@@pphhpp..nneett so we can mail you a copy immediately. The PHP Group 2008 PHP(1)




Contact us      |      About us      |      Term of use      |       Copyright © 2000-2019 MyWebUniversity.com ™