Download the PHP package hnesk/todate without Composer

On this page you can find all versions of the php package hnesk/todate. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package todate

ToDate

A PHP date expression library with a corresponding domain specific language (DSL)

Describing DateConditions as strings (DSL)

This library contains a DSL (domain specific language) to describe complex date scenarios as simple strings. This DSL expressions get parsed to a tree of expressions, that can be evaluated for any given date.

Sounds complicated? No it isn't.

Imagine your garbage gets picked up, every first monday each month. How would communicate that fact to a machine?

What about every first and third monday each month?

What about every second and last monday each month? (using pythons notion of negative numbers as counting from the end).

Ok, let's say every monday, but not if its Easter monday (constant Easter means Easter sunday)

Or whit monday (50 days after Easter sunday), independence day, or christmas?

All date conditions in the ToDate/Condition namespace can be created with the corresponding DSL string syntax

DSL Building Blocks

All of these conditions are mapped to single \ToDate\Condition\AbstractDateCondition instance.

Date

Just one fixed date, example only on Independence Day 2021

Easter based date conditions

Every whit sunday

DateModulo

Every 2 weeks (14 days) starting from 2021-03-12

DayAndMonth

Every independence day

DayOfMonth

Every 1st and 15th each month

or every 1st till 9th each month

DayOfWeek

Every saturday and sunday

DayOfWeekMonth

Every 1st and 3rd monday

Every 2nd and last (=-1 like in python) monday

Month

In the summertime

Year

The corona years

Combinig Conditions with logical operators

All conditions can be combined with AND, OR and NOT to form complex date conditions.

Examples

see also the executable examples


All versions of todate with dependencies

PHP Build Version
Package Version
Requires php Version >=7.0.0
smuuf/php-peg Version ~2.0
ext-calendar Version *
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package hnesk/todate contains the following files

Loading the files please wait ....