PHP code example of effectra / clock
1. Go to this page and download the library: Download effectra/clock library. Choose the download type require. 2. Extract the ZIP file and open the index.php. 3. Add this code to the index.php.
<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
effectra / clock example snippets
// Create a new instance of the Clock class
$clock = new \Effectra\Clock\Clock();
// Get the current time as a DateTimeImmutable object
$currentDateTime = $clock->now();
// Get the current timestamp as an integer
$currentTimestamp = $clock->timestamp();