php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #30537 Predefined Constants Missing Magic constants
Submitted: 2004-10-23 03:16 UTC Modified: 2004-10-29 21:10 UTC
From: ammar at gnuix dot com Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS: *
Private report: No CVE-ID: None
 [2004-10-23 03:16 UTC] ammar at gnuix dot com
Description:
------------
 I checked the reserved constants page
http://www.php.net/manual/en/reserved.constants.php

And followed both links,

Core Predefined Constants -- Constants defined in the PHP core, Zend, and SAPI modules
Standard Predefined Constants -- Constants defined in PHP by default

I didn't find the following constants:

__FILE__
__LINE__
__FUNCTION__
__CLASS__
__METHOD__

Maybe they are somewhere else, but for usability and convenience I think they should be added to this page, maybe in a seperate category.

P.S: Please reply to my email address directly, as i'm not subscribed to this list

Regards,
    Ammar Ibrahim



Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-10-26 06:39 UTC] philip@php.net
Some notes:

- These constants are linked to from here:
http://php.net/constants

- reserved.constants should link to language.constants but as of now reserved.constants contains the following text:
 <!--
 This file shold only be present in the English doc tree.
 If you copy it over to your translation tree you will
 be hunted down relentlessly! You have been warned! :)
 -->
So perhaps it shouldn't be touched, or, the above note be removed. 

- The [predefined/reserved] constants pages should in the very least be 'grouped together' a little better.
 [2004-10-28 02:44 UTC] ammar at gnuix dot com
But I think they need to be also linked from the reserved constants page. Information should be available wherever appropriate, I had hard time finding those magic constants, if they were linked from that page things would have been better :)
 [2004-10-28 10:19 UTC] vrana@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.

"See also: Magic constants." in Core Predefined Constants.
 [2004-10-29 19:51 UTC] philip@php.net
The issue of translation has not been resolved.
 [2004-10-29 20:34 UTC] vrana@php.net
The file reserved.constants contains only entities and no translatable text. I believe it's the only reason to not copy this file to other language versions (to let compiler fall to English).
 [2004-10-29 21:10 UTC] goba@php.net
Philip, feel free to touch the file, modify as you see fit. If you need translateable text in it, use snippets (entities). If some text is not applicable to go to an entity, then we need to discuss this a bit further.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Wed Aug 06 00:00:02 2025 UTC