PHP code example of daycode / fictive

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

    

daycode / fictive example snippets


use Daycode\Fictive\Fictive;

$handlePersons = app(Fictive::class)
    ->count(1)
    ->handlePersons(); // Person Service Example

$handlePersons(function ($person) {
    User::create([
        'name' => $person->fullName(),
        'email' => $person->email(),
        'email_verified_at' => now(),
        'password' => bcrypt('password'),
        'phone_number' => $person->phoneNumber(),
        'religion' => $person->religion(),
        'hobby' => $person->hobby(),
        'blood_group' => $person->bloodGroup(),
        'job_description' => $person->jobTitle(),
    ]);
});