adcuz / seasonizr
Installs: 764
Dependents: 0
Suggesters: 0
Security: 0
Stars: 2
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/adcuz/seasonizr
Requires (Dev)
- nesbot/carbon: ^1.33
- phpunit/phpunit: ^7.3
This package is not auto-updated.
Last update: 2025-10-12 10:44:30 UTC
README
A simple library that returns the season in a given country on a given date. This is for non-critical use, such as changing a bit of UI based on the current season, and should be treated as very low accuracy.
Install
composer require adcuz/seasonizr
Usage
use Adcuz\Seasonizr\Conversion; $conversion = new Conversion(); // Season based on current date $conversion->country('GB');
Output (if today was a winter day):
winter
Specific date:
// June 2nd 2018 $date = (new \DateTime())->setDate(2018, 6, 2); $conversion->country('GB', $date);
Output:
summer
Help Wanted
I threw this together quickly to satisfy a need in a project, I'd like to improve it with the help of the community.
License
This project is open-sourced software licensed under the Apache License 2.0