Ultimate Posts Widget - Version 2.0.1

Version Description

  • Fixes issue loading multiple widgets on the same page and using the same template
  • Adds a default title to the widget for new instances
  • Documentation improvements
Download this release

Release Info

Developer bostondv
Plugin Icon wp plugin Ultimate Posts Widget
Version 2.0.1
Comparing to
See all releases

Code changes from version 2.0.0 to 2.0.1

assets/banner-772x250.png ADDED
Binary file
screenshot-1.png → assets/screenshot-1.png RENAMED
File without changes
screenshot-2.png → assets/screenshot-2.png RENAMED
File without changes
screenshot-3.png → assets/screenshot-3.png RENAMED
File without changes
screenshot-4.png → assets/screenshot-4.png RENAMED
File without changes
screenshot-5.png → assets/screenshot-5.png RENAMED
File without changes
readme.txt CHANGED
@@ -6,7 +6,7 @@ License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: widget, recent posts, custom post types, sticky posts, featured image, post thumbnail, excerpts, category, custom fields, list pages, widget query, microformats, customizable widget, categories widget, tags widget, excerpt, widget templates, post author, post date, custom query, ultimate posts, comments, orderby, comment count
7
  Requires at least: 3.6
8
  Tested up to: 4.0
9
- Stable tag: 2.0.0
10
 
11
  The ultimate widget for displaying posts, custom post types or sticky posts with an array of options.
12
 
@@ -41,44 +41,57 @@ Designed for both the average user and developer, Ultimate Posts Widgets aims to
41
  * Change excerpt length (in words)
42
  * Order by date, title, number of comments, random or a custom field
43
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
44
  = Filters =
45
 
46
- `upw_enqueue_styles` (boolean)
 
47
  Allows changing whether to load the template CSS file(s).
48
 
49
- `upw_widget_title` (string)
 
50
  Allows changing the widget title.
51
 
52
- `upw_wp_query_args` (array)
 
53
  Allows changing the WP_Query arguments for the widget.
54
 
55
- `upw_custom_template_path` (string)
 
56
  Allows changing the default custom template path.
57
 
58
  = Templates =
59
 
60
- `legacy`
61
- As of version 2.0.0 we changed the widget HTML markup. For installs prior to 2.0.0 you can use the legacy template to retain the old HTML markup and compatibility.
62
-
63
- `standard`
64
- The new standard template as of version 2.0.0. It features better HTML5 markup, improved styling on various themes without the need for custom CSS, and hfeed microformat.
65
 
66
- `custom`
67
- As of version 2.0.0 you can now provide your own custom template files. In your theme, create a folder named `upw` then copy one of the templates from the plugin into this folder and edit as needed. In the widget settings under *Display* tab, choose *Custom* template from the drop down and enter the file name (excluding .PHP) into the subsequent field. For example, if your template is named `custom.php` then enter `custom` in the Custom Template Name field.
68
 
69
- = More Information =
70
 
71
- * For help use [wordpress.org](http://wordpress.org/support/plugin/ultimate-posts-widget/)
72
- * Fork or contribute on [Github](https://github.com/bostondv/ultimate-posts-widget/)
73
- * Visit [our website](http://pomelodesign.com/) for more
74
- * Follow me on [Twitter](http://twitter.com/bostondv/)
75
- * View my other [WordPress Plugins](http://profiles.wordpress.org/bostondv/)
76
 
77
- = Support =
78
 
79
- Did you enjoy this plugin? Please [donate to support ongoing development](http://pomelodesign.com/donate/). Your contribution would be greatly appreciated.
80
 
81
- == Frequently Asked Questions ==
82
 
83
  = Thumbnail images are not displaying =
84
 
@@ -106,6 +119,11 @@ This plugin uses the [timthumb library](http://www.binarymoon.co.uk/projects/tim
106
 
107
  == Changelog ==
108
 
 
 
 
 
 
109
  = 2.0.0 =
110
 
111
  * Added a new standard template and custom template support
6
  Tags: widget, recent posts, custom post types, sticky posts, featured image, post thumbnail, excerpts, category, custom fields, list pages, widget query, microformats, customizable widget, categories widget, tags widget, excerpt, widget templates, post author, post date, custom query, ultimate posts, comments, orderby, comment count
7
  Requires at least: 3.6
8
  Tested up to: 4.0
9
+ Stable tag: 2.0.1
10
 
11
  The ultimate widget for displaying posts, custom post types or sticky posts with an array of options.
12
 
41
  * Change excerpt length (in words)
42
  * Order by date, title, number of comments, random or a custom field
43
 
44
+ = Documentation =
45
+
46
+ See the [FAQ tab](https://wordpress.org/plugins/ultimate-posts-widget/faq/) for documentation on custom templates, hooks, common issues, and more.
47
+
48
+ = More Information =
49
+
50
+ * For help use [wordpress.org](http://wordpress.org/support/plugin/ultimate-posts-widget/)
51
+ * Fork or contribute on [Github](https://github.com/bostondv/ultimate-posts-widget/)
52
+ * Visit [our website](http://pomelodesign.com/) for more
53
+ * Follow me on [Twitter](http://twitter.com/bostondv/)
54
+ * View my other [WordPress Plugins](http://profiles.wordpress.org/bostondv/)
55
+
56
+ = Support =
57
+
58
+ Did you enjoy this plugin? Please [donate to support ongoing development](http://pomelodesign.com/donate/). Your contribution would be greatly appreciated.
59
+
60
+ == Frequently Asked Questions ==
61
+
62
  = Filters =
63
 
64
+ **upw_enqueue_styles** *(boolean)*
65
+
66
  Allows changing whether to load the template CSS file(s).
67
 
68
+ **upw_widget_title** *(string)*
69
+
70
  Allows changing the widget title.
71
 
72
+ **upw_wp_query_args** *(array)*
73
+
74
  Allows changing the WP_Query arguments for the widget.
75
 
76
+ **upw_custom_template_path** *(string)*
77
+
78
  Allows changing the default custom template path.
79
 
80
  = Templates =
81
 
82
+ **legacy**
 
 
 
 
83
 
84
+ As of version 2.0.0 we changed the widget HTML markup. For installs prior to 2.0.0 you can use the legacy template to retain the old HTML markup and compatibility.
 
85
 
86
+ **standard**
87
 
88
+ The new standard template as of version 2.0.0. It features better HTML5 markup, improved styling on various themes without the need for custom CSS, and hfeed microformat.
 
 
 
 
89
 
90
+ **custom**
91
 
92
+ As of version 2.0.0 you can now provide your own custom template files. To do this, create a directory named `upw` in your theme and copy a template from the plugin's `templates` directory. Edit as needed.
93
 
94
+ Then, in the widget settings under the *Display* tab, choose *Custom* from the *Template* drop down. In the *Custom Template Name* field that appears and enter the file name of your template (excluding .php). For example, if your template is named `custom.php` then enter `custom` in the *Custom Template Name* field.
95
 
96
  = Thumbnail images are not displaying =
97
 
119
 
120
  == Changelog ==
121
 
122
+ = 2.0.1 =
123
+ * Fixes issue loading multiple widgets on the same page and using the same template
124
+ * Adds a default title to the widget for new instances
125
+ * Documentation improvements
126
+
127
  = 2.0.0 =
128
 
129
  * Added a new standard template and custom template support
ultimate-posts-widget.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Ultimate Posts Widget
4
  Plugin URI: http://wordpress.org/plugins/ultimate-posts-widget/
5
  Description: The ultimate widget for displaying posts, custom post types or sticky posts with an array of options.
6
- Version: 2.0.0
7
  Author: Boston Dell-Vandenberg
8
  Author URI: http://pomelodesign.com
9
  Text Domain: upw
@@ -194,14 +194,14 @@ if ( !class_exists( 'WP_Widget_Ultimate_Posts' ) ) {
194
  if ($instance['template'] === 'custom') {
195
  $custom_template_path = apply_filters('upw_custom_template_path', '/upw/' . $instance['template_custom'] . '.php');
196
  if (locate_template($custom_template_path)) {
197
- require_once(get_stylesheet_directory() . $custom_template_path);
198
  } else {
199
- require_once('templates/standard.php');
200
  }
201
  } elseif ($instance['template']) {
202
- require_once('templates/' . $instance['template'] . '.php');
203
  } else {
204
- require_once('templates/legacy.php');
205
  }
206
 
207
  // Reset the global $the_post as this query will have stomped on it
@@ -277,7 +277,7 @@ if ( !class_exists( 'WP_Widget_Ultimate_Posts' ) ) {
277
 
278
  // Set default arguments
279
  $instance = wp_parse_args( (array) $instance, array(
280
- 'title' => '',
281
  'class' => '',
282
  'title_link' => '' ,
283
  'number' => '5',
@@ -621,7 +621,7 @@ if ( !class_exists( 'WP_Widget_Ultimate_Posts' ) ) {
621
  </div>
622
 
623
  <p class="upw-credits">
624
- Enjoy this plugin? Please <a href="http://pomelodesign.com/donate/" target="_blank">donate to support development</a>.
625
  </p>
626
 
627
  <?php if ( $instance ) { ?>
3
  Plugin Name: Ultimate Posts Widget
4
  Plugin URI: http://wordpress.org/plugins/ultimate-posts-widget/
5
  Description: The ultimate widget for displaying posts, custom post types or sticky posts with an array of options.
6
+ Version: 2.0.1
7
  Author: Boston Dell-Vandenberg
8
  Author URI: http://pomelodesign.com
9
  Text Domain: upw
194
  if ($instance['template'] === 'custom') {
195
  $custom_template_path = apply_filters('upw_custom_template_path', '/upw/' . $instance['template_custom'] . '.php');
196
  if (locate_template($custom_template_path)) {
197
+ include get_stylesheet_directory() . $custom_template_path;
198
  } else {
199
+ include 'templates/standard.php';
200
  }
201
  } elseif ($instance['template']) {
202
+ include 'templates/' . $instance['template'] . '.php';
203
  } else {
204
+ include 'templates/legacy.php';
205
  }
206
 
207
  // Reset the global $the_post as this query will have stomped on it
277
 
278
  // Set default arguments
279
  $instance = wp_parse_args( (array) $instance, array(
280
+ 'title' => __('Ultimate Posts', 'upw'),
281
  'class' => '',
282
  'title_link' => '' ,
283
  'number' => '5',
621
  </div>
622
 
623
  <p class="upw-credits">
624
+ <?php _e('Enjoy this plugin? Please <a href="http://pomelodesign.com/donate/" target="_blank">donate to support development</a>.', 'upw'); ?>
625
  </p>
626
 
627
  <?php if ( $instance ) { ?>