php cli模式下获取参数的方法

转载声明:http://blog.csdn.net/fdipzone/article/details/51945892

php在cli模式下接收参数有两种方法

1.使用argv数组

2.使用getopt方法
getopt() 函数的用法,详细见php官方手册

posted on 2017-04-26 17:17  mingaixin  阅读(338)  评论(0编辑  收藏  举报