reference/ctype/functions/ctype-digit.xml
e20e74073379710a4f6316734c42996c8fbf9beb
...
...
@@ -11,7 +11,7 @@
11
11
&reftitle.description;
12
12
<methodsynopsis>
13
13
<type>bool</type><methodname>ctype_digit</methodname>
14
-
<methodparam><type>string</type><parameter>text</parameter></methodparam>
14
+
<methodparam><type>mixed</type><parameter>text</parameter></methodparam>
15
15
</methodsynopsis>
16
16
<para>
17
17
Checks if all of the characters in the provided <type>string</type>,
...
...
@@ -28,6 +28,8 @@
28
28
<listitem>
29
29
<para>
30
30
The tested string.
31
+
&note.ctype.parameter.integer;
32
+
&note.ctype.parameter.non-string;
31
33
</para>
32
34
</listitem>
33
35
</varlistentry>
...
...
@@ -40,31 +42,7 @@
40
42
<para>
41
43
Returns &true; if every character in the string
42
44
<parameter>text</parameter> is a decimal digit, &false; otherwise.
43
-
</para>
44
-
</refsect1>
45
-

46
-
<refsect1 role="changelog">
47
-
&reftitle.changelog;
48
-
<para>
49
-
<informaltable>
50
-
<tgroup cols="2">
51
-
<thead>
52
-
<row>
53
-
<entry>&Version;</entry>
54
-
<entry>&Description;</entry>
55
-
</row>
56
-
</thead>
57
-
<tbody>
58
-
<row>
59
-
<entry>5.1.0</entry>
60
-
<entry>
61
-
Before PHP 5.1.0, this function returned &true;
62
-
when <parameter>text</parameter> was an empty string.
63
-
</entry>
64
-
</row>
65
-
</tbody>
66
-
</tgroup>
67
-
</informaltable>
45
+
&ctype.result.empty-string;
68
46
</para>
69
47
</refsect1>
70
48

...
...
@@ -119,19 +97,6 @@ is_numeric($integer); // true
119
97
</para>
120
98
</refsect1>
121
99

122
-
<refsect1 role="notes">
123
-
&reftitle.notes;
124
-
<note>
125
-
<para>
126
-
This function expects a <type>string</type> to be useful, so for example passing
127
-
in an <type>integer</type> may not return the expected result. However, also note that
128
-
HTML forms will result in numeric strings and not integers. See also the
129
-
<link linkend="language.types">types</link> section of the manual.
130
-
</para>
131
-
</note>
132
-
&note.ctype.parameter.integer;
133
-
</refsect1>
134
-

135
100
<refsect1 role="seealso">
136
101
&reftitle.seealso;
137
102
<para>
...
...
@@ -141,6 +106,7 @@ is_numeric($integer); // true
141
106
<member><function>is_numeric</function></member>
142
107
<member><function>is_int</function></member>
143
108
<member><function>is_string</function></member>
109
+
<member><function>IntlChar::isdigit</function></member>
144
110
</simplelist>
145
111
</para>
146
112
</refsect1>
147
113