Download the PHP package ypid/suncalc without Composer

On this page you can find all versions of the php package ypid/suncalc. 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 suncalc

suncalc

Build Status BSD licensed haxelib version NPM version Packagist version

GitHub stars GitHub forks GitHub watchers GitHub open issues GitHub closed issues GitHub open pull requests GitHub closed pull requests

PHPPackages Rank PHPPackages Referenced By Packagist monthly downloads Packagist daily downloads Packagist total downloads

The SunCalc module allows to calculate sun position, sunlight phases (times for sunrise, sunset, dusk, etc.), moon position and lunar phase for the given location and time.

SunCalc was ported to Haxe by Robin ypid Schneider to allow using it in a planed rewrite of the opening hours library.

It is based on the JavaScript implementation created by Vladimir Agafonkin (@mourner) as a part of the SunCalc.net project.

Most calculations are based on the formulas given in the excellent Astronomy Answers articles about position of the sun and the planets. You can read about different twilight phases calculated by SunCalc in the Twilight article on Wikipedia.

Refer to the API documentation for details.

Install

Install the library for your favorite language by executing one of the following commands:

Getting started

Check out the following example to get started.

TODO

Maintainer/tester with PHP knowledge wanted :wink:

Composer does provide a autoload feature which is currently not used. My experience with PHP is very limited which is the reason I wrote in Haxe and generated this PHP target only because all unit tests for PHP passed. If you know how to properly support the autoload feature for this library, I will be happy to integrate it.

Internals

This library was automatically build using Haxe to target PHP.

Refer to https://github.com/ypid/suncalc when you want to contribute. Note that you should only report issues against the PHP target repository when you think the issue only occurs in the PHP port of this library. If you are unsure, report against the source repository instead.

Unit testing

Unit testing is done against the source repository in Haxe, as well as against each transcompile target (PHP in this case). You can check them out in the source repository.

Maintainer

License

BSD-2-Clause


All versions of suncalc with dependencies

PHP Build Version
Package Version
No informations.
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 ypid/suncalc contains the following files

Loading the files please wait ....