Download the PHP package ealore/progress without Composer

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

Build Status

Progress

A generator of Bootstrap 3 progress bars based on dates

Installation

composer require ealore\progress

If you use Laravel 5 you may add the service provider to config/app.php providers array

Ealore\Progress\ProgressServiceProvider::class,

Usage

$progress = new Ealore\Progress('2013-01-01','2013-12-31','P30D');
echo $progress->render(); // generate the html for the progress bar, based on the dates you provided.

The HTML generated looks like this:

<div class="progress">
    <div class="progress-bar progress-bar-success" style="width: 31.24%"><span class="sr-only">31.24%</span></div>
    <div class="progress-bar progress-bar-warning" style="width: 2.81%"><span class="sr-only">2.81%</span></div>
    <div class="progress-bar progress-bar-danger" style="width: 65.95%"><span class="sr-only">65.95%</span></div>
</div>

You may use also setters:

$progress = new Ealore\Progress\Progress;
$progress->setStartDate('2013-01-01');
$progress->setWarningThresholdAsDate('2013-12-01');
$progress->setEndDate('2013-12-31');

echo $progress->render();

Threshold of the 'warning' section

You may set a threshold to mark the start of the 'warning' section in two ways:

Default values

When start and end are not set, the default values used are defined from the initialization timestamp: one month before for the start and next month for the end. By default the 'warning' section starts one month before the end. If start and end are not set this means that the 'warning' starts at the moment of initialization. The threshold may be removed completely by setting it to zero:

$progress->setWarningThresholdAsString('P0D');

Take a look at the examples below, the last one shows the effect of setting the warning interval to zero.

Examples

Contribution

PRs are welcome

Roadmap


All versions of progress with dependencies

PHP Build Version
Package Version
Requires nesbot/carbon Version ^1.21
illuminate/support Version ^5.1
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 ealore/progress contains the following files

Loading the files please wait ...