PHP code example of ppelgrims / moveable-feasts

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

    

ppelgrims / moveable-feasts example snippets


Carbon::mixin(new MoveableFeasts\MoveableFeastsMixin());
Carbon::easter()->toDateString();     // "2018-04-01"
Carbon::easter(2020)->toDateString(); // "2020-04-12"

Carbon::ashWednesday();

Carbon::palmSunday();
Carbon::holyMonday();
Carbon::holyTuesDay();
Carbon::holyWednesday();
Carbon::easter();
Carbon::easterSunday(); // alias
Carbon::easterMonday();

Carbon::ascension();

Carbon::pentacost();
Carbon::pentacostSunday(); // alias
Carbon::pentacostMonday();

Carbon::advent();
Carbon::christmas();