php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #34702 preg_* functions area of the manual
Submitted: 2005-10-01 20:04 UTC Modified: 2005-10-02 18:24 UTC
From: ryan_huff at knl dot cc Assigned:
Status: Not a bug Package: Documentation problem
PHP Version: Irrelevant OS: Irrelevant
Private report: No CVE-ID: None
 [2005-10-01 20:04 UTC] ryan_huff at knl dot cc
Description:
------------
As a suggestion, I would like to see the preg_* areas of the manual re-visited someday.

The format character syntax for preg can be extremely complex to someone who is not familiar with such, especially when it comes to the dbl escape for the search/replace of reserved words/characters.  Then there is knowing when you need to use the parens, or the brackets ...ect.

I feel that the manual barely explains how to use preg, even in alien-speak.  Sure, the manual gives the definition and outlines where all the paramiters go but doesn't explian how to use them and more importantly, what conditions have to exist to use them. 

I think it would go along way to provide some more "basic" example code on the page covering different / common use, that way the reader can break it down in their head and apply it to their situation.

Thanks, 

MsJetEngineError

Reproduce code:
---------------
http://us3.php.net/manual/en/function.preg-match.php

Expected result:
----------------
A more intuitive area of the manual for the preg_* functions

Actual result:
--------------
A barely understandable area of the manual

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-10-02 18:24 UTC] nlopess@php.net
The regex syntax page provides a clean and easy reference for the preg_* functions regex syntax.
Of course you won't be able to (easily) learn Regular Expressions from a simple manual page. You need to buy a book about the topic. This is not an easy subject!
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jun 03 04:01:31 2024 UTC