|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #69012 examples in echo documentation are misleading
Submitted: 2015-02-08 02:45 UTC Modified: 2019-02-12 16:16 UTC
From: teo8976 at gmail dot com Assigned: girgias (profile)
Status: Closed Package: Strings related
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: teo8976 at gmail dot com
New email:
PHP Version: OS:


 [2015-02-08 02:45 UTC] teo8976 at gmail dot com
From manual page:

Example #1 echo examples

Many of the examples (all except the first one, the 8th and 9th, and the last three) have nothing to do with echo itself but with how string literals work. Those examples would make perfect sense replacing 'echo' with '$somevar=' 

Putting those examples in the documentation for echo
a) bloats the documentation of one language construct with unrelated stuff
b) is misleading and ambiguous, potentially leading the reader to wrongly think that variable substitution in literal strings, or heredoc syntax, are somehow specific to echo, while they are not and can be used also without echo


doc-fix-69012 (last revision 2019-01-20 17:55 UTC by

Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2016-06-14 16:40 UTC]
-Status: Open +Status: Verified
 [2017-01-28 12:53 UTC]
-Package: Documentation problem +Package: Strings related
 [2018-12-31 17:05 UTC]
-Status: Verified +Status: Assigned -Assigned To: +Assigned To: girgias
 [2019-01-20 17:55 UTC]
The following patch has been added/updated:

Patch Name: doc-fix-69012
Revision:   1548006922
 [2019-02-12 16:16 UTC]
Automatic comment from SVN on behalf of cmb
Log: Fix #69012: examples in echo documentation are misleading

Patch provided by girgias.
 [2019-02-12 16:16 UTC]
-Status: Assigned +Status: Closed
 [2019-02-12 16:16 UTC]
This bug has been fixed in the documentation's XML sources. Since the
online and downloadable versions of the documentation need some time
to get updated, we would like to ask you to be a bit patient.

Thank you for the report, and for helping us make our documentation better.
 [2019-02-18 16:41 UTC]
Automatic comment on behalf of cmb
Log: Fix #69012: examples in echo documentation are misleading
 [2019-02-19 20:22 UTC]
Automatic comment on behalf of cmb
Log: Fix #69012: examples in echo documentation are misleading
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Thu Dec 12 11:01:25 2019 UTC