php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #62618 third param isn't optional
Submitted: 2012-07-20 09:35 UTC Modified: 2012-07-20 10:08 UTC
From: adax2000 at gmail dot com Assigned:
Status: Not a bug Package: *General Issues
PHP Version: 5.3.15 OS:
Private report: No CVE-ID: None
 [2012-07-20 09:35 UTC] adax2000 at gmail dot com
Description:
------------
---
From manual page: http://www.php.net/function.preg-match-all#refsect1-function.preg-match-all-description
---

third param in preg_match_all is required and omitting it will get
you false on return in contrary to documation that states
it's optional, what's strange in preg_match it's not required


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2012-07-20 09:37 UTC] aharvey@php.net
-Status: Open +Status: Not a bug
 [2012-07-20 09:37 UTC] aharvey@php.net
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit http://www.php.net/support.php as this bug system is not the
appropriate forum for asking support questions.  Due to the volume
of reports we can not explain in detail here why your report is not
a bug.  The support channels will be able to provide an explanation
for you.

Thank you for your interest in PHP.

The third parameter is definitely optional. You have another problem in your code.
 [2012-07-20 09:52 UTC] adax2000 at gmail dot com
are you sure, that's what i'm getting
Debug Warning: /deep2/public_html/wp-content/themes/deep/functions.php line 52 - preg_match_all() expects at least 3 parameters, 2 given
 [2012-07-20 10:08 UTC] aharvey@php.net
My apologies; it's only optional as of 5.4.0 (per the changelog on the preg_match_all() manual page).
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu May 02 13:01:30 2024 UTC