Changeset 1479786
- Timestamp:
- 08/21/2016 03:08:47 AM (10 years ago)
- Location:
- well-handled/trunk
- Files:
-
- 4 edited
-
functions-handlebars.php (modified) (1 diff)
-
help/template.md (modified) (1 diff)
-
index.php (modified) (1 diff)
-
readme.txt (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
well-handled/trunk/functions-handlebars.php
r1463492 r1479786 236 236 return ''; 237 237 238 $value = (int) $context->get($data[0]); 238 $value = $context->get($data[0]); 239 if(is_array($value)) 240 $value = count($value); 241 else 242 $value = (int) $value; 239 243 $singular = $context->get($data[1]); 240 244 $plural = $context->get($data[2]); -
well-handled/trunk/help/template.md
r1463492 r1479786 286 286 ### Inflect 287 287 288 To singularize or plurialize words based on count `{{#inflect count $singular $plurial}}` 288 To singularize or plurialize words based on count `{{#inflect count $singular $plurial}}`. The `count` value may be an integer or an array; if the latter the array's size will be used as the value. 289 289 290 290 {{#inflect count '%d book' '%d books'}} -
well-handled/trunk/index.php
r1463492 r1479786 4 4 Plugin URI: https://well-handled.io 5 5 Description: Easy and powerful handlebar/mustache email template management for developers. 6 Version: 1.5 6 Version: 1.5.1 7 7 Author: well-handled.io 8 8 Author URI: https://well-handled.io -
well-handled/trunk/readme.txt
r1463492 r1479786 4 4 Tags: template, handlebar, mustache, css, email, transactional, analytics 5 5 Requires at least: 4.4 6 Tested up to: 4. 5.36 Tested up to: 4.6 7 7 Stable tag: trunk 8 8 License: GPLv2 or later … … 67 67 == Changelog == 68 68 69 = 1.5.1 = 70 * [improved] #inflect helper can now accept an array as the 'count' variable; 71 69 72 = 1.5 = 70 73 * [new] Fragment support (e.g. common template parts); … … 87 90 == Upgrade Notice == 88 91 92 = 1.5.1 = 93 * [improved] #inflect helper can now accept an array as the 'count' variable; 94 95 = 1.5 = 96 * [new] Fragment support (e.g. common template parts); 97 * [new] Added array helpers: avg, count, join, min, max, sum; 98 * [new] Added comparison helpers: ifGreater, ifLesser; 99 * [new] Added misc helpers: currency, nl2br, now, wp_bloginfo, wp_site_url; 100 * [improved] Full overhaul of Handlebar parsing; 101 * [improved] Cleaned up documentation; 102 89 103 = 1.0.2 = 90 104 * Inaugural WordPress.org release!
Note: See TracChangeset
for help on using the changeset viewer.