gmdate

(PHP 4, PHP 5, PHP 7, PHP 8)

gmdateFormatiert eine GMT/UTC Zeit-/Datumsangabe

Beschreibung

gmdate(string $format, ?int $timestamp = null): string

Identisch mit der Funktion date(), ausgenommen, dass die zurückgegebene Zeitangabe Greenwich Mean Time (GMT) entspricht.

Parameter-Liste

format

Das Format des ausgegebenen Datumsstrings. Siehe auch die Formatierungsoptionen der Funktion date().

timestamp

Der optionale Parameter timestamp ist ein Unix-Timestamp als int oder die aktuelle lokale Zeit, wenn timestamp nicht übergeben wurde oder null ist. Er entspricht dann also dem Ergebnis der Funktion time().

Rückgabewerte

Gibt einen formatierten Datumsstring zurück.

Changelog

Version Beschreibung
8.0.0 timestamp ist jetzt nullbar.

Beispiele

Beispiel #1 gmdate()-Beispiel

Wenn das Skript in Finnland (GMT +0200) ausgeführt wird, gibt die erste Zeile "Jan 01 1998 00:00:00" aus, während die zweite Zeile "Dec 31 1997 22:00:00" zurückgibt.

<?php
echo date("M d Y H:i:s"mktime(000111998));
echo 
gmdate("M d Y H:i:s"mktime(000111998));
?>

Siehe auch

Hier Kannst Du einen Kommentar verfassen


Bitte gib mindestens 10 Zeichen ein.
Wird geladen... Bitte warte.
* Pflichtangabe
Es sind noch keine Kommentare vorhanden.

Was genau bedeutet "Vibe Coding"? Ein tiefgehender Blick für Entwickler

In der Welt der Softwareentwicklung gibt es unzählige Wege, wie man an ein Projekt herangeht. Manche schwören auf strikte Planung, andere auf bewährte Algorithmen und wieder andere lassen sich von etwas ganz anderem leiten: ihrem Gefühl. ...

admin

Autor : admin
Kategorie: Software & Web-Development

PHP cURL-Tutorial: Verwendung von cURL zum Durchführen von HTTP-Anfragen

cURL ist eine leistungsstarke PHP-Erweiterung, die es Ihnen ermöglicht, mit verschiedenen Servern über verschiedene Protokolle wie HTTP, HTTPS, FTP und mehr zu kommunizieren. ...

TheMax

Autor : TheMax
Kategorie: PHP-Tutorials

Midjourney Tutorial - Anleitung für Anfänger

Über Midjourney, dem Tool zur Erstellung digitaler Bilder mithilfe von künstlicher Intelligenz, gibt es ein informatives Video mit dem Titel "Midjourney Tutorial auf Deutsch - Anleitung für Anfänger" ...

Mike94

Autor : Mike94
Kategorie: KI Tutorials

Tutorial veröffentlichen

Tutorial veröffentlichen

Teile Dein Wissen mit anderen Entwicklern weltweit

Du bist Profi in deinem Bereich und möchtest dein Wissen teilen, dann melde dich jetzt an und teile es mit unserer PHP-Community

mehr erfahren

Tutorial veröffentlichen

Safe Diablo 4 Item Deals on U4GM: What You Need to Know

Progressing through Diablo 4 often requires more than just skill. Building a powerful character means collecting high-quality equipment, valuable ...

Geschrieben von Jimekalmiya am 01.07.2026 01:59:45
Forum: Bücher-Forum
+27734009912 medium sorcerer prof jomo denis in new york city, usa

Prof Jomo Denis is a practicing medium who works all over the world. He helps in the most difficult situations, quickly and effectively. His influ ...

Geschrieben von profjomo am 01.07.2026 00:38:49
Forum: Off-Topic Diskussionen
Genie invocations and summons in Accra Ghana+27734009912

Jinn’s, Genies are also living beings but they are made of fire. Genie or Jinn’s can be conquered by human beings by special invocations and i ...

Geschrieben von profjomo am 01.07.2026 00:36:36
Forum: Off-Topic Diskussionen
+27734009912 Spell to punish an evil person in Kingston Jamaica

There is nothing worse than knowing someone is out to harm you or destroy you. Even if they are not outwardly threatening you with physical harm, ...

Geschrieben von profjomo am 01.07.2026 00:34:37
Forum: Off-Topic Diskussionen