2017 © Pedro Peláez
 

yii2-extension yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

image

geoffry304/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  • Tuesday, June 12, 2018
  • by Geoffry304
  • Repository
  • 1 Watchers
  • 0 Stars
  • 5 Installations
  • JavaScript
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

yii2-widget-timer

Simple timer widget for yii2-based applications, (*1)

Widget timer on jquery plugin.

Displays time elapsed since timer started in format HH:MM:SS: * HH - elapsed hours; * ММ - elapsed minutes; * CC - elapsed seconds; It can run automatically (after page is load) or manually. It is possible to stop and reset the timer., (*2)

Installation

The preferred way to install extension is via composer. Check the composer.json for this extension's requirements and dependencies., (*3)

To install, either run, (*4)

$ php composer.phar require geoffry304/yii2-widget-timer "*"

or add, (*5)

"geoffry304/yii2-widget-timer": "*"

to the require section of your composer.json., (*6)

Usage

Upload all necessary components and prepare widget, (*7)

use geoffry304\timer\Timer
Timer::widget([
    'options' => [
        'container' => '.timer',
        'autoStart' => true,
    ]
])

Add an html tag with class name 'timer' in any place of your html. Content of this tag will be replaced by widget., (*8)

<div class="timer"></div>

Working copy of plugin will be in global scope and can be controlled via $.fn.timer.worker. Timer will run automatically after initialization (if 'autoStart' parameter is specified) and assigned to a container with class 'timer' ('container' property)., (*9)

Run the timer, (*10)

    $.fn.timer.worker.go();

Plugin configuration: * container - html selector of timer container element (default - '.timer'); * autoStart – whether to start timer automatically after initialization (default - true); * hours – start hours count from this value (default '00'); * minutes – start minutes count from this value (default '00'); * seconds – start seconds count from this value (default '00'); * animate - whether to run animation when timer starts (blinking); * animationSpeed - speed of animation; * animationTimes - number of blinking;, (*11)

Plugin control: * init(value) - initialize the timer, only displays the timer (value == false) or run timer automatically (value == true), if timer is already running this actions will stop the timer and reset all of its counters (hours, minutes, seconds); * go() - run the timer; * stop(value) - stop the timer and keep counters (hours, minutes, seconds) (value == false) or reset them (value == true); * flush() - reset the timer counters (hours, minutes, seconds). * timeAsString() - return the current time values as string., (*12)

License

yii2-widget-timer is released under the BSD 3-Clause License. See the bundled LICENSE.md for details., (*13)

The Versions

12/06 2018

dev-master

9999999-dev https://github.com/geoffry304/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD-3-Clause

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch

12/06 2018

v1.4

1.4.0.0 https://github.com/geoffry304/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD-3-Clause

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch

12/06 2018

v1.3

1.3.0.0 https://github.com/geoffry304/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD-3-Clause

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch

12/06 2018

v1.2

1.2.0.0 https://github.com/geoffry304/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD-3-Clause

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch

26/04 2016

v1.1

1.1.0.0 https://github.com/aayaresko/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD 3-Clause License

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch

08/05 2015

v1.0.1

1.0.1.0 https://github.com/aayaresko/yii2-widget-timer

Yii2 widget that displays controllable timer/stopwatch

  Sources   Download

BSD 3-Clause License

The Requires

  • php >=5.3.0

 

by Avatar aayaresko

plugin extension yii2 jquery widget timer counter stopwatch