PHP code example of spaanproductions / laravel-carbon-holidays

1. Go to this page and download the library: Download spaanproductions/laravel-carbon-holidays 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/ */

    

spaanproductions / laravel-carbon-holidays example snippets


use \Carbon\Carbon;

// NewYear
$date = Carbon::createFromDate(2021, 01, 01);
$date->isHoliday(); // true