php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #3149 Unable to pass "-" or "+" as parameter when running as command-line
Submitted: 2000-01-08 15:27 UTC Modified: 2002-01-28 16:47 UTC
From: gblatz at blatzheim dot com Assigned:
Status: Closed Package: Feature/Change Request
PHP Version: 4.0 Beta 3 OS: Linux
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: gblatz at blatzheim dot com
New email:
PHP Version: OS:

 

 [2000-01-08 15:27 UTC] gblatz at blatzheim dot com
It is impossible to pass parameters containing "-" or "+" when running php as command-line script.

Even a parameter like "test-2-test" (containing dash not as first character) or "+41123456789" will fail. 

For example   

    test.php3 test-2-test
or
    test.php3 +41123456789

will fail. I find no way to escape these characters to pass them. Maybe even more will be not allowed?

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2000-12-12 05:16 UTC] stas@php.net
- seems to work OK, but + doesn't work indeed because of URL
translation.
 [2002-01-28 16:47 UTC] yohgaki@php.net
I guess this is already done with CLI SAPI, isn't?
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Sat May 10 22:01:26 2025 UTC