PHP code example of openlss / func-time
1. Go to this page and download the library: Download openlss/func-time 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/ */
openlss / func-time example snippets
$timestamp = time()-3600;
$ago = age($timestamp); //returns 1 hour
$timestamp = time()+3600
$in = future_age($timestamp); //returns 1 hour
$time = timestamp()-7200;
$hours = hours($time); //returns 2