PHP code example of conceptbyte / time-traveller

1. Go to this page and download the library: Download conceptbyte/time-traveller 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/ */

    

conceptbyte / time-traveller example snippets


'providers' => [
    ...,
    'ConceptByte\TimeTraveller\TimeTravellerServiceProvider'
]
 artisan vendor:publish

class Post extents Model
{
    use TimeTravel;
    
    public function getBy()
    {
        return Auth::user()->name;
    }
}

Post::at('58781813')->find(1);

Post::find(1);

Post::with('revisions')->first();
 artisan time-traveller:clear
config/app.php
config/timetraveller.php
abstract public function getBy()