PHP code example of yogeshjoshi / laravel-time-logger
1. Go to this page and download the library: Download yogeshjoshi/laravel-time-logger 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/ */
yogeshjoshi / laravel-time-logger example snippets
using class
use LaravelTimeLogger\LaravelTimeLogger;
function exportCSV() {
$timer = new LaravelTimeLogger("Export CSV");
$timer->start();
// do work here
$timer->stop();
}
using helper function
$timer = timerlog('Helper test');
$timer->start();
// do work here
$timer->stop();
bash
php artisan vendor:publish --tag=laravel-time-logger