php的命令⼤全,php常⽤命令⼤全1.php -v 查看版本号
PHP 5.5.11 (cli) (built: Apr 29 2014 12:35:52)
Copyright (c) 1997-2014 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2014 Zend Technologies
2.php -h 查看帮助
3.php -m 查看安装的模块
[PHP Modules]
Core
type
4.php -i 查看php信息(查看php.ini⾮常⽅便)
[[email protected] lib]# php -i | grep php.ini
Configuration File (php.ini) Path => /usr/local/lib
Loaded Configuration File => /usr/local/lib/php.ini
5.php --ini 显⽰配置⽂件名字
Configuration File (php.ini) Path: /usr/local/lib
Loaded Configuration File: /usr/local/lib/php.ini
Scan for additional .ini files in: (none)
Additional .ini files parsed: (none)
6.php -f 执⾏php⽂件
[[email protected] phpTest]# php -f helloworld.php
helloword
更多使⽤技巧请看php -h
Usage: php [options] [-f] [--] []
php [options] -r [--] []
php [options] [-B ] -R [-E ] [--] []
php [options] [-B ] -F [-E ] [--] []
php [options] -S : [-t docroot]
php [options] -- []
php [options] -a
-a Run interactively
-c | Look for php.ini file in this directory
-n No php.ini file will be used
-d foo[=bar] Define INI entry foo with value ‘bar‘php手机版下载
-
e Generate extended information for debugger/profiler
-f Parse and execute .
-h This help
-i PHP information
-l Syntax check only (lint)
-m Show compiled in modules
-r Run PHP without using script tags
-B Run PHP before processing input lines
-R Run PHP for every input line
-F Parse and execute for every input line
-E Run PHP after processing all input lines
-
H Hide any passed arguments from external tools.
-S : Run with built-in web server.
-t Specify document root for built-in web server.
-s Output HTML syntax highlighted source.
-v Version number
-w Output source with stripped comments and whitespace.
-z Load Zend extension .
< Arguments passed to script. Use -- args when first argument starts with - or script is read from stdin
--ini Show configuration file names
--rf Show information about function .
--rc Show information about class .
--re Show information about extension .
--rz Show information about Zend extension .
--ri Show configuration for extension .

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。