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. PHP高效获取远程图片尺寸和大小

    /** * 获取远程图片的宽高和体积大小 * * @param string $url 远程图片的链接 * @param string $type 获取远程图片资源的方式, 默认为 curl 可选 f ...

  2. hdu 1217 Arbitrage

    Flody多源最短路 #include<cstdio> #include<cstring> #include<string> #include<cmath&g ...

  3. I’m stuck!

    I’m stuck! 问题描述 给定一个R行C列的地图,地图的每一个方格可能是'#', '+', '-', '|', '.', 'S', 'T'七个字符中的一个,分别表示如下意思: '#': 任何时候 ...

  4. JS复习:第二十章

    一.JSON 1.JSON的语法可以表示以下三种类型的值: (1)简单值:字符串.数值.布尔值和null.如:5,“Hello,World!” (2)对象:javascript中对象字面量: var ...

  5. web工程师经常遇到的专业术语(待补充)

    接口(API) SEO指的是将从各个方面对网站内容进行优化,方便搜索引擎检索.搜索引擎工作的原理就是对网站内容进行抓取,然后解析. 白帽SEO:合理的对网站内容进行优化进而增加搜索引擎友好度. 黑帽S ...

  6. 城市字符串----转数组( 加空格---preg_split) 正则分割字符串 --> 成数组

    正则 以 斜杠开始 斜杠 结束   斜杠 包围起来  /  / 字母 反斜杠 转义  \s    space 匹配空格 多个空格 [ \s  ]+   中括号 包围起来 public function ...

  7. php缓存总结

    php缓存技术: 1.全页面静态化缓存;2.页面部分缓存;3.数据缓存;4.查询缓存;5.按内容变更进行缓;6.内存式缓存;7.apache缓存模块;8.php APC缓存扩展;9.Opcode缓存. ...

  8. Gentoo启动菜单设置:使用官方LiveDVD Grub主题

    设置Gentoo Grub启动主题 拷贝官方LiveDVD grub主题: 下载官方DVD,找到 /boot/grub/themes/GenGrub目录,并拷贝出来. 安装GenGrub主题: 将Ge ...

  9. fatal error RC1004: unexpected end of file found处理方法

    资源编译器错误 RC1004 错误消息 遇到意外的文件结束 此错误是由于文本文件的最后一行中缺少换行符和回车符而造成的.

  10. hitTest:withEvent:方法流程

    此方法可实现点击穿透.点击下层视图功能. 一. hitTest:withEvent:调用过程 iOS系统检测到手指触摸(Touch)操作时会将其放入当前活动Application的事件队列,UIApp ...