Edit report at https://bugs.php.net/bug.php?id=74363&edit=1
ID: 74363
Updated by: [email protected]
Reported by: olafvdspek at gmail dot com
Summary: echo doesn't accept multiple arguments
-Status: Open
+Status: Not a bug
Type: Bug
Package: *General Issues
Operating System: Debian
PHP Version: 5.6.30
Block user comment: N
Private report: N
New Comment:
Not a bug, explained in manual as you've later realized.
Previous Comments:
------------------------------------------------------------------------
[2017-04-02 12:53:22] olafvdspek at gmail dot com
Grr, this seems to simple to be true.
> Additionally, if you want to pass more than one parameter to echo, the parameters must not be enclosed within parentheses.
> void echo ( string $arg1 [, string $... ] )
Perhaps this should be split into two lines, one without parentheses and with multiple arguments and one with parentheses and a single argument.
Or multiple arguments should be supported in both forms..
------------------------------------------------------------------------
[2017-04-02 12:49:30] olafvdspek at gmail dot com
Description:
------------
Echo doesn't appear to accept multiple arguments
PHP 5.6.30-0+deb8u1 (cli) (built: Feb 8 2017 08:50:21)
PHP 7.0.16-3 (cli) (built: Feb 22 2017 10:03:06) ( NTS )
Test script:
---------------
<?php
echo('A', 'B');
Expected result:
----------------
AB
Actual result:
--------------
PHP Parse error: syntax error, unexpected ',' in /root/a.php on line 2
------------------------------------------------------------------------
--
Edit this bug report at https://bugs.php.net/bug.php?id=74363&edit=1
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.