2017 © Pedro Peláez
 

library fun-box

Function collection

image

zeptech/fun-box

Function collection

  • Thursday, July 10, 2014
  • by pgraham
  • Repository
  • 1 Watchers
  • 1 Stars
  • 108 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

FunBox

A set of useful utility functions., (*1)

Install

Install via Composer:, (*2)

{
    "require": {
        "zeptech/fun-box": "dev-master"
    }
}

Initialization

In order to use functions Fun Box must be initialized because php doesn't provide function autoloading. Once initialized, functions are included using the ensureFn function., (*3)

<?php
// ... Initialize composer
FunBox::init();
ensureFn('passwordPrompt');

// ...
if ($interactive) {
    $pw = passwordPrompt();
}

Functions

List of functions provided by Fun Box, (*4)

announceWait

Output a countdown to the command line., (*5)

announceWait($waitTime, $message = 'Commencing');
  • @param waitTime integer Number of seconds to count down before continuing.
  • @param message string What will happen when the countdown is complete.

passwordPrompt

Prompt the user for a password from the command line., (*6)

passwordPrompt($prompt = 'password: ');
  • @param prompt string The prompt for the user.

The Versions

10/07 2014

dev-master

9999999-dev

Function collection

  Sources   Download

BSD

The Requires

 

by Philip Graham

utility functions