|
93 | 93 |
|
94 | 94 | <refsect1 role="examples"> |
95 | 95 | &reftitle.examples; |
96 | | - <para> |
97 | | - <example> |
98 | | - <title><function>gmstrftime</function> example</title> |
99 | | - <programlisting role="php"> |
| 96 | + <example> |
| 97 | + <title><function>gmstrftime</function> example</title> |
| 98 | + <programlisting role="php"> |
100 | 99 | <![CDATA[ |
101 | 100 | <?php |
102 | | -setlocale(LC_TIME, 'en_US'); |
103 | | -echo strftime("%b %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)) . "\n"; |
104 | | -echo gmstrftime("%b %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)) . "\n"; |
| 101 | +
|
| 102 | +setlocale(LC_TIME, 'es_ES.UTF-8'); |
| 103 | +date_default_timezone_set('EST'); |
| 104 | +
|
| 105 | +echo strftime("%B %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)) . "\n"; |
| 106 | +echo gmstrftime("%B %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)); |
105 | 107 | ]]> |
106 | | - </programlisting> |
107 | | - </example> |
108 | | - </para> |
| 108 | + </programlisting> |
| 109 | + &example.outputs; |
| 110 | + <screen> |
| 111 | +<![CDATA[ |
| 112 | +Deprecated: Function strftime() is deprecated since 8.1, use IntlDateFormatter::format() instead in script on line 6 |
| 113 | +diciembre 31 1998 20:00:00 |
| 114 | +
|
| 115 | +Deprecated: Function gmstrftime() is deprecated since 8.1, use IntlDateFormatter::format() instead in script on line 7 |
| 116 | +enero 01 1999 01:00:00 |
| 117 | +]]> |
| 118 | + </screen> |
| 119 | + </example> |
109 | 120 | </refsect1> |
110 | 121 |
|
111 | 122 | <refsect1 role="seealso"> |
|
0 commit comments