1
0
mirror of https://github.com/php/doc-pl.git synced 2026-03-24 15:12:16 +01:00
Files
Maciej Sobaczewski 9b8816fec9 Sync with EN
2026-03-02 20:32:03 +01:00

137 lines
4.0 KiB
XML
Executable File

<?xml version="1.0" encoding="UTF-8"?>
<!-- EN-Revision: 3a8c3e77df070a046c9d5b56b68926ca2d7e5ee3 Maintainer: qrak Status: ready -->
<!-- $Revision$ -->
<!-- CREDITS: sobak -->
<refentry xml:id="function.gmstrftime" xmlns="http://docbook.org/ns/docbook">
<refnamediv>
<refname>gmstrftime</refname>
<refpurpose>Formatuje czas/datę ze strefy GMT/UTC zgodnie z ustawieniami locale</refpurpose>
</refnamediv>
<refsynopsisdiv>
&warn.deprecated.function-8-1-0.alternatives;
<simplelist role="alternatives">
<member><function>gmdate</function></member>
<member><methodname>IntlDateFormatter::format</methodname></member>
</simplelist>
</refsynopsisdiv>
<refsect1 role="description">
&reftitle.description;
<methodsynopsis>
<modifier role="attribute">#[\Deprecated]</modifier>
<type class="union"><type>string</type><type>false</type></type><methodname>gmstrftime</methodname>
<methodparam><type>string</type><parameter>format</parameter></methodparam>
<methodparam choice="opt"><type class="union"><type>int</type><type>null</type></type><parameter>timestamp</parameter><initializer>&null;</initializer></methodparam>
</methodsynopsis>
<para>
Zachowuje się identycznie jak <function>strftime</function> z tym
wyjątkiem, że zwracany jest czas strefy Greenwich (Greenwich Mean Time -
GMT). Na przykład, uruchomiona we Wschodnim Czasie Standardowym
(GMT -0500) pierwsza linia poniżej wyświetla "Dec 31 1998 20:00:00",
podczas gdy druga "Jan 01 1999 01:00:00".
</para>
</refsect1>
<refsect1 role="parameters">
&reftitle.parameters;
<para>
<variablelist>
<varlistentry>
<term><parameter>format</parameter></term>
<listitem>
<para>
Zobacz opis przy <function>strftime</function>.
</para>
</listitem>
</varlistentry>
&date.timestamp.description;
</variablelist>
</para>
</refsect1>
<refsect1 role="returnvalues">
&reftitle.returnvalues;
<para>
Zwraca łańcuch sformatowany zgodnie z podanym łańcuchem formatów,
używając znacznika czasu podanego jako <parameter>timestamp</parameter> lub obecnego
czasu lokalnego, jeżeli nie podano znacznika. Nazwy miesięcy, dni tygodnia i
innych ciągów zależnych od języka, bazują na obecnej lokalizacji ustawionej
funkcją <function>setlocale</function>.
W wypadku błędu zwracane jest &false;.
</para>
</refsect1>
<refsect1 role="changelog">
&reftitle.changelog;
<para>
<informaltable>
<tgroup cols="2">
<thead>
<row>
<entry>&Version;</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row>
<entry>8.0.0</entry>
<entry>
Parametr <parameter>timestamp</parameter> dopuszcza teraz &null;.
</entry>
</row>
</tbody>
</tgroup>
</informaltable>
</para>
</refsect1>
<refsect1 role="examples">
&reftitle.examples;
<para>
<example>
<title>Przykład użycia <function>gmstrftime</function></title>
<programlisting role="php">
<![CDATA[
<?php
setlocale(LC_TIME, 'en_US');
echo strftime("%b %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)) . "\n";
echo gmstrftime("%b %d %Y %H:%M:%S", mktime(20, 0, 0, 12, 31, 98)) . "\n";
]]>
</programlisting>
</example>
</para>
</refsect1>
<refsect1 role="seealso">
&reftitle.seealso;
<para>
<simplelist>
<member><methodname>IntlDateFormatter::format</methodname></member>
<member><methodname>DateTimeInterface::format</methodname></member>
<member><function>strftime</function></member>
</simplelist>
</para>
</refsect1>
</refentry>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->