1.php -v 查看版本号

 
[root@rs-2 lib]# 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 查看安装的模块
 
[root@rs-2 lib]# php -m
 
[PHP Modules]
 
Core
 
type
 
 
4.php -i 查看php信息(查看php.ini非常方便)
 
[root@rs-2 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 显示配置文件名字
 
[root@rs-2 ~]# 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文件
 
[root@rs-2 phpTest]# php -f helloworld.php
 
helloword
 
 
更多使用技巧请看php -h
 
[root@rs-2 ~]# php -h
 
Usage: php [options] [-f] [--] [args...]
 
php [options] -r [--] [args...]
 
php [options] [-B ] -R [-E ] [--] [args...]
 
php [options] [-B ] -F [-E ] [--] [args...]
 
php [options] -S : [-t docroot]
 
php [options] -- [args...]
 
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'
 
-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 .
 
 
args... 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 .
 
http://www.35ui.cn/post/20151226538.html

php常用命令大全的更多相关文章

  1. db2常用命令大全

    #显示这个DB2错误的解释信息(SQLSTATE 5位数字)db2 ? 42704 #显示这个SQLCODE的解释信息(SQLCODE 四位数字) db2 ? SQL0204N ##查看数据库指定配置 ...

  2. linux 常用命令大全

    linux 常用命令大全 系统信息 arch 显示机器的处理器架构(1) uname -m 显示机器的处理器架构(2) uname -r 显示正在使用的内核版本 dmidecode -q 显示硬件系统 ...

  3. Ubuntu常用命令大全(转)

    点评:Ubuntu常用命令大全,学习ubuntn系统的朋友可以收藏下,用ctrl+F查找即可 一.文件/文件夹管理 ls 列出当前目录文件(不包括隐含文件) ls -a 列出当前目录文件(包括隐含文件 ...

  4. 100个命令Linux常用命令大全

    Linux常用命令大全100条: 1,echo "aa" > test.txt 和 echo "bb" >> test.txt//>将原 ...

  5. Linux常用命令大全(非常全!!!)

    Linux常用命令大全(非常全!!!) 最近都在和Linux打交道,感觉还不错.我觉得Linux相比windows比较麻烦的就是很多东西都要用命令来控制,当然,这也是很多人喜欢linux的原因,比较短 ...

  6. Linux常用命令大全(转)

    (转)Linux常用命令大全(非常全!!!) 最近都在和Linux打交道,感觉还不错.我觉得Linux相比windows比较麻烦的就是很多东西都要用命令来控制,当然,这也是很多人喜欢linux的原因, ...

  7. 18-10-09 Linux常用命令大全(非常全!!!)

     Linux常用命令大全(非常全!!!)   Linux常用命令大全(非常全!!!) 最近都在和Linux打交道,感觉还不错.我觉得Linux相比windows比较麻烦的就是很多东西都要用命令来控制, ...

  8. Ubuntu常用命令大全[显示桌面]

    Ubuntu常用命令大全 查看软件xxx安装内容 #dpkg -L xxx 查找软件 #apt-cache search 正则表达式 查找文件属于哪个包 #dpkg -S filename apt-f ...

  9. [转] Linux常用命令大全(非常全!!!)

    出处:https://www.cnblogs.com/yjd_hycf_space/p/7730690.html Linux常用命令大全(非常全!!!) 最近都在和Linux打交道,感觉还不错.我觉得 ...

  10. Ubuntu 常用命令大全

    Ubuntu 常用命令大全查看软件 xxx 安装内容#dpkg -L xxx查找软件#apt-cache search 正则表达式查找文件属于哪个包#dpkg -S filename apt-file ...

随机推荐

  1. ACM常用模板

    数论: 中国剩余定理(互质与非互质通用版) ],r[]; int e_gcd(int a,int b,int &x,int &y) { ) { x=; y=; return a; } ...

  2. Android 边框圆角

    RelativeLayout 圆角实现:  drawable目录下面定义shape的xml文件: mall_header_rel_bg.xml <?xml version="1.0&q ...

  3. Python编码问题整理【转】

    认识常见编码 GB2312是中国规定的汉字编码,也可以说是简体中文的字符集编码 GBK 是 GB2312的扩展 ,除了兼容GB2312外,它还能显示繁体中文,还有日文的假名 cp936:中文本地系统是 ...

  4. /tmp 和 /var/tmp 的区别

    /tmp is meant as fast (possibly small) storage with a short time to live (TTL). Many systems clean / ...

  5. reshape2 数据操作 数据融合 (melt)

    前面一篇讲了cast,想必已经见识到了reshape2的强大,当然在使用cast时配合上melt这种强大的揉数据能力才能表现的淋漓尽致. 下面我们来看下,melt这个函数以及它的特点. melt(da ...

  6. 浙大pat 1025题解

    1025. PAT Ranking (25) 时间限制 200 ms 内存限制 32000 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue Programmi ...

  7. AOE 网络

    1.定义 如果在无向环的带权有向图中 - 用有向边表示一个工程中的活动 - 用边上的权值表示活动的持续时间 - 用顶点表示事件 则这样的有向图叫做用边表示活动的网络,简称AOE网络 AOE在工程方面非 ...

  8. 深入JVM锁机制1-synchronized

    目前在Java中存在两种锁机制:synchronized和Lock,Lock接口及其实现类是JDK5增加的内容,其作者是大名鼎鼎的并发专家Doug Lea.本文并不比较synchronized与Loc ...

  9. Delphi用ADOquery主从表例子(转总结)

    http://blog.csdn.net/kandy_zheng/article/details/1639184 在sql server 的northwide 中建立主表 create table s ...

  10. LeetCode OJ 59. Spiral Matrix II

    Given an integer n, generate a square matrix filled with elements from 1 to n2 in spiral order. For ...