php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Doc Bug #50094 COM and .Net constants not defined
Submitted: 2009-11-05 19:53 UTC Modified: 2009-11-06 10:57 UTC
From: zelnaga at gmail dot com Assigned:
Status: Closed Package: Documentation problem
PHP Version: Irrelevant OS:
Private report: No CVE-ID: None
View Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
If you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: zelnaga at gmail dot com
New email:
PHP Version: OS:

 

 [2009-11-05 19:53 UTC] zelnaga at gmail dot com
Description:
------------
<http://php.net/dom.constants> mentions the constants, their values, and gives a description of each.  <http://php.net/com.constants> mentions the constants and that's it.  <http://php.net/variant-get-type> returns an int.  What constant does that int correspond to?  Looking at the documentation, such as it currently is, sure isn't going to tell you.


Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-11-05 20:15 UTC] zelnaga at gmail dot com
Here's a script that'll enumerate on the constants and their values:

<?php
$constants = array(
    'CLSCTX_INPROC_SERVER', 'CLSCTX_INPROC_HANDLER', 'CLSCTX_LOCAL_SERVER', 'CLSCTX_REMOTE_SERVER',
    'CLSCTX_ALL', 'VT_NULL', 'VT_EMPTY', 'VT_UI1', 'VT_I2', 'VT_I4', 'VT_R4', 'VT_R8', 'VT_BOOL',
    'VT_ERROR', 'VT_CY', 'VT_DATE', 'VT_BSTR', 'VT_DECIMAL', 'VT_UNKNOWN', 'VT_DISPATCH', 'VT_VARIANT',
    'VT_I1', 'VT_UI2', 'VT_UI4', 'VT_INT', 'VT_UINT', 'VT_ARRAY', 'VT_BYREF', 'CP_ACP', 'CP_MACCP',
    'CP_OEMCP', 'CP_UTF7', 'CP_UTF8', 'CP_SYMBOL', 'CP_THREAD_ACP', 'VARCMP_LT', 'VARCMP_EQ',
    'VARCMP_GT', 'VARCMP_NULL', 'NORM_IGNORECASE', 'NORM_IGNORENONSPACE', 'NORM_IGNORESYMBOLS',
    'NORM_IGNOREWIDTH', 'NORM_IGNOREKANATYPE', 'NORM_IGNOREKASHIDA', 'DISP_E_DIVBYZERO',
    'DISP_E_OVERFLOW', 'MK_E_UNAVAILABLE'
);
foreach ($constants as $constant) {
    echo $constant . ' == ' . constant($constant) . '<br />';
}
?>

Note how NORM_IGNOREKASHIDA yields a "Couldn't find constant" warning.  At least it does for me...
 [2009-11-06 10:57 UTC] svn@php.net
Automatic comment from SVN on behalf of rquadling
Revision: http://svn.php.net/viewvc/?view=revision&revision=290373
Log: Restructured to table and added constant values. Fix #50094
 [2009-11-06 10:57 UTC] rquadling@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:09 UTC] phpdocbot@php.net
Automatic comment on behalf of rquadling
Revision: http://git.php.net/?p=doc/en.git;a=commit;h=e2603fd0afc79558f0d2167bca91b72afc29d278
Log: Restructured to table and added constant values. Fix #50094
 
PHP Copyright © 2001-2026 The PHP Group
All rights reserved.
Last updated: Thu Oct 08 09:00:02 2026 UTC