3v4l.org

run code in 300+ PHP versions simultaneously
<?php $date = new DateTimeImmutable("2022-09-28 06:30:05.011183"); $timestampMs = (int) ($date->getTimestamp() . $date->format('v')); $timestampS1000 = (int) ($date->getTimestamp() * 1000); var_dump($timestampMs); var_dump($timestampS1000); var_dump($timestampMs === $timestampS1000);
Output for git.master, git.master_jit, rfc.property-hooks
int(1664339405011) int(1664339405000) bool(false)

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
27.75 ms | 405 KiB | 5 Q