php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #28580 Typo in documentation
Submitted: 2004-05-30 17:48 UTC Modified: 2004-06-10 17:47 UTC
Votes:1
Avg. Score:2.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: chruker at tiscali dot dk Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS: All
Private report: No CVE-ID: None
 [2004-05-30 17:48 UTC] chruker at tiscali dot dk
Description:
------------
Hi

On the page describing the xml_parser_get_option function there is a typo in the documentation.

Its the line reading:
'This function returns FALSE if parser does not refer to a valid parser, or if the option could not be set. Else the option's value is returned.'

The typo is this part:  'or if the option could not be set.'  I don't assume that a *get_option function actually sets an option :-)


Expected result:
----------------
I don't know if the code returns false if the option isn't set or doesn't exists.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-05-30 17:52 UTC] chruker at tiscali dot dk
Direct link to the page in the online documentation:
http://www.php.net/manual/en/function.xml-parser-get-option.php
 [2004-05-30 21:46 UTC] jed at jed dot bz
Although I was able to find this "typo" in the documentation, I have some doubts it is a typo.

If you submit a bogus 'option' to xml_parser_get_option() it might return FALSE if that option isn't really an option. For example:

$x = xml_parser_get_option($xml, 135971923752512);

May return FALSE because there is no option that *can be set* by that number.

Just a thought.
 [2004-05-30 21:48 UTC] jed at jed dot bz
It also generates a Warning, but it still might return FALSE.
 [2004-05-30 23:19 UTC] chruker at tiscali dot dk
I just tried:

echo xml_parser_get_option($xml, 1241243243)."<BR>";

but it doesn't print anything at all.
 [2004-05-31 11:46 UTC] goba@php.net
It should only print <br> if the function returns false, so I would not be surprised...
 [2004-06-10 17:47 UTC] nlopess@php.net
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.


 [2020-02-07 06:12 UTC] phpdocbot@php.net
Automatic comment on behalf of nlopess
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=90bfdbab07ca77ffaf7d47a32483de9d103537ec
Log: fix #28580
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Jul 30 21:00:03 2025 UTC