我正在尝试下载composer,但它不起作用。。。我使用的命令行来自:https://getcomposer.org/download/这是回应:
php -r "readfile('https://getcomposer.org/installer');" | php
Error in argument 1, char 2: option not found r
Content-type: text/html
Usage: php [-q] [-h] [-s] [-v] [-i] [-f <file>]
php <file> [args...]
-a Run interactively
-C Do not chdir to the script's directory
-c <path>|<file> 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 <file> Parse <file>. Implies `-q'
-h This help
-i PHP information
-l Syntax check only (lint)
-m Show compiled in modules
-q Quiet-mode. Suppress HTTP Header output.
-s Display colour syntax highlighted source.
-v Version number
-w Display source with stripped comments and whitespace.
-z <file> Load Zend extension <file>.
Composer不支持PHP 5.2-您必须至少升级到5.3,但请记住,对PHP 5.3的安全支持在几年前就结束了,最新也是唯一支持的版本是5.6(7.0版本即将推出)。
如果您仍在生产中运行PHP5.2,则应该考虑升级。