Plugin Directory

Changeset 1205720


Ignore:
Timestamp:
07/24/2015 12:29:28 PM (11 years ago)
Author:
toxicToad
Message:

Added tick_multiplier shortcode attribute.
Cleaned up obsolete files.
Tested on WordPress 4.2.3

Location:
jellyfish-counter-widget/trunk
Files:
2 deleted
3 edited

Legend:

Unmodified
Added
Removed
  • jellyfish-counter-widget/trunk/jellyfish-counter-widget.php

    r1079853 r1205720  
    55    Description: Fully configurable static or animated odometer style rotating counters.
    66    Author: Rob Miller
    7     Version: 1.4.2
     7    Version: 1.4.3
    88    Author URI: http://strawberryjellyfish.com/
    99*/
     
    6969            'timestamp' => false,
    7070            'interval' => 1,
     71            'tick_multiplier' => 1,
    7172            'active' => true
    7273        ), $atts );
     
    114115            data-timestamp="' . esc_attr( $a['timestamp'] ) .'"
    115116            data-active="' . esc_attr( $a['active'] ) .'"
     117            data-tick-multiplier="' . esc_attr( $a['tick_multiplier'] ) .'"
    116118            data-interval="' . esc_attr( $a['interval'] ) .'">
    117119        </div>';
    118     $jellyfish_cw_shortcode_id++;
    119120    return $counter_html;
    120121}
  • jellyfish-counter-widget/trunk/jellyfish-odometer-class/js/jellyfish-odometer.js

    r1079853 r1205720  
    33//  Jellyfish Counter Widget for WordPress
    44//  http://strawberryjellyfish.com/wordpress-plugins/jellyfish-counter/
    5 //  Version 1.9
     5//  Version 1.9.1
    66//  Copyright (C) 2014 Robert Miller
    77//  http://strawberryjellyfish.com
     
    5252    this.timestamp = false;
    5353    this.interval = 1;
     54    this.tickMultiplier = 1;
    5455    this.active = true;
    5556    this.completedFunction = function(){};
    56     this.currentValue = this.startValue;
    5757
    5858    // get all instance specific configuration from container data attributes
     
    6060    for (var key in opts) {
    6161        this[key] = opts[key];
     62    }
     63
     64    this.currentValue = this.startValue * this.tickMultiplier;
     65
     66    if (typeof(this.endValue) != 'undefined' && this.endValue != '' && this.currentValue > this.endValue) {
     67        this.currentValue = this.endValue;
    6268    }
    6369
     
    101107    this.init = function() {
    102108        this.drawOdometer(this.container);
    103         this.set(this.startValue);
    104109        if ((this.endValue != this.startValue) && this.active) {
    105110            this.updateOdometer();
     
    226231                this.currentValue - 0.15 : this.currentValue + 0.15;
    227232            this.wholeNumber = this.wholeNumber + 0.15;
    228             if (this.wholeNumber >= 1) {
     233            if (this.wholeNumber >= this.tickMultiplier) {
    229234                this.wholeNumber = 0;
    230235                this.currentValue = Math.round(this.currentValue);
  • jellyfish-counter-widget/trunk/readme.txt

    r1079853 r1205720  
    66Tags: counter, odometer, milometer, animated, widget, totaliser
    77Requires at least: 3.0
    8 Tested up to: 4.1
    9 Stable tag: 1.4.2
     8Tested up to: 4.2.3
     9Stable tag: 1.4.3
    1010License: GPLv2 or later
    1111License URI: http://www.gnu.org/licenses/gpl-2.0.html
     
    2020
    2121Counters can be used as a manually updated total, an automatic counter that
    22 updates over time or just as an animated visual effect. Each counter can count upwards or downwards making them suitable for both incrementing totals or countdown situations. A great visual effect for travel blogs or any website
    23 that wants to display a running total or countdown of anything.
     22updates over time or just as an animated visual effect.
     23Each counter can count upwards or downwards making them suitable for both
     24incrementing totals or countdown situations. A great visual effect for travel
     25blogs or any website that wants to display a running total or countdown of anything.
    2426
    2527Jellyfish Counters are highly configurable through the widget interface, and
     
    2830individual settings for totals and appearance.
    2931
    30 New Shortcode support allows you to generate a counter directly within any
     32Shortcode support allows you to generate a counter directly within any
    3133post or page content making counters no longer limited to your sidebar or
    3234other widgetable area.
     
    3941= Demo =
    4042
    41 Here's a typical counter in action at http://sharkaroo.net/map
    42 Using an animated counter adds visual and narrative impact to an otherwise
    43 static value.
    44 
    45 Check out the plugin homepage for more demos and further information:
     43Check out the plugin homepage for demos and further information:
    4644http://strawberryjellyfish.com/wordpress-plugins/jellyfish-counter/
    4745
     
    5351Or
    5452
    55 Extract the zip file and just drop the contents in the wp-content/plugins/ directory of your WordPress installation and then activate the Plugin from
     53Extract the zip file and just drop the contents in the wp-content/plugins/
     54directory of your WordPress installation and then activate the Plugin from
    5655Plugins page.
    5756
     
    6766== Frequently Asked Questions ==
    6867
     68= How can I make the counter adapt on responsive layouts? =
     69
     70The current version of the counter does not scale easily, try to make your
     71counter small enough to fit your smallest view. The all new future version 2.0
     72will be more responsive design friendly.
     73
     74= Can I use the counter to track visitors to my website? =
     75
     76No, it's not that kind of a counter.
     77
     78= Can I use the counter to show my post count/comment count/user count? =
     79
     80Not yet, possibly down the track in version 2.0+ .
     81
     82= I've a really cool idea for a feature, can you include it? =
     83
     84I'm always interested in suggestions, send them on through!
     85
    6986
    7087== Screenshots ==
     
    7289
    7390== Changelog ==
     91
     92= 1.4.3 =
     93* Updated WordPress tested version to 4.2.3
     94* Cleanup: removed obsolete js and css files.
     95* Minor Bugfix: fixed initialisation of current value.
     96* New Feature: tick_multiplier parameter added to shortcode, see shortcode usage for details.
    7497
    7598= 1.4.2 =
     
    143166Note:
    144167
    145 There have been changes in class names after vesrion 1.0, if you have added
     168There have been changes in class names after version 1.0, if you have added
    146169custom counter styles to your WordPress theme you may need to make minor
    147170changes to reflect the new CSS classes applied to counter elements.
     
    235258* direction : a, string 'up' or 'down'
    236259* interval : The number of seconds between updates of a continuous counter
     260* tick_multiplier : the number of units the counter will increment every interval (defaults to 1)
    237261* timestamp : false or a string representing the starting time for the counter
    238262
Note: See TracChangeset for help on using the changeset viewer.