Version Description
- Internationalized and added Spanish. (Props: @elarequi)
- Added support for Media post types with "image/" mime types to be displayed directly in the default template.
Download this release
Release Info
Developer | dpe415 |
Plugin | Flexible Posts Widget |
Version | 3.1 |
Comparing to | |
See all releases |
Code changes from version 3.1.1 to 3.1
- flexible-posts-widget.php +4 -4
- readme.txt +15 -10
flexible-posts-widget.php
CHANGED
@@ -4,7 +4,7 @@ Plugin Name: Flexible Posts Widget
|
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/flexible-posts-widget/
|
5 |
Author: dpe415
|
6 |
Author URI: http://dpedesign.com
|
7 |
-
Version: 3.1
|
8 |
Description: An advanced posts display widget with many options: get posts by post type, taxonomy & term; sorting & ordering; feature images; custom templates and more.
|
9 |
License: GPL2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
@@ -32,7 +32,7 @@ if( !defined('ABSPATH') )
|
|
32 |
|
33 |
// Define our version number
|
34 |
if( !defined('DPE_FP_Version') )
|
35 |
-
define( 'DPE_FP_Version', '3.1
|
36 |
|
37 |
/**
|
38 |
* Plugin Initialization
|
@@ -276,7 +276,7 @@ class DPE_Flexible_Posts_Widget extends WP_Widget {
|
|
276 |
* 2) parent template, 3) plugin resources. will look in the flexible-posts-widget/
|
277 |
* directory in a theme and the views/ directory in the plugin
|
278 |
*
|
279 |
-
*
|
280 |
* by Matt Wiebe at Modern Tribe, Inc.
|
281 |
* http://wordpress.org/extend/plugins/image-widget/
|
282 |
*
|
@@ -286,7 +286,7 @@ class DPE_Flexible_Posts_Widget extends WP_Widget {
|
|
286 |
public function getTemplateHierarchy( $template ) {
|
287 |
|
288 |
// whether or not .php was added
|
289 |
-
$template_slug =
|
290 |
$template = $template_slug . '.php';
|
291 |
|
292 |
if ( $theme_file = locate_template( array( 'flexible-posts-widget/' . $template ) ) ) {
|
4 |
Plugin URI: http://wordpress.org/extend/plugins/flexible-posts-widget/
|
5 |
Author: dpe415
|
6 |
Author URI: http://dpedesign.com
|
7 |
+
Version: 3.1
|
8 |
Description: An advanced posts display widget with many options: get posts by post type, taxonomy & term; sorting & ordering; feature images; custom templates and more.
|
9 |
License: GPL2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
32 |
|
33 |
// Define our version number
|
34 |
if( !defined('DPE_FP_Version') )
|
35 |
+
define( 'DPE_FP_Version', '3.1' );
|
36 |
|
37 |
/**
|
38 |
* Plugin Initialization
|
276 |
* 2) parent template, 3) plugin resources. will look in the flexible-posts-widget/
|
277 |
* directory in a theme and the views/ directory in the plugin
|
278 |
*
|
279 |
+
* Function generously borrowed from the amazing image-widget
|
280 |
* by Matt Wiebe at Modern Tribe, Inc.
|
281 |
* http://wordpress.org/extend/plugins/image-widget/
|
282 |
*
|
286 |
public function getTemplateHierarchy( $template ) {
|
287 |
|
288 |
// whether or not .php was added
|
289 |
+
$template_slug = rtrim( $template, '.php' );
|
290 |
$template = $template_slug . '.php';
|
291 |
|
292 |
if ( $theme_file = locate_template( array( 'flexible-posts-widget/' . $template ) ) ) {
|
readme.txt
CHANGED
@@ -4,13 +4,14 @@ Donate link: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_i
|
|
4 |
Tags: widget, widgets, posts, categories, tags, recent posts, thumbnails, custom post types, custom taxonomies, feature image
|
5 |
Requires at least: 3.2
|
6 |
Tested up to: 3.5.1
|
7 |
-
Stable tag: 3.1
|
8 |
License: GPL2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
An advanced posts display widget with many options. Display posts in your sidebars any way you'd like!
|
12 |
|
13 |
== Description ==
|
|
|
14 |
The default Recent Posts widget is exceptionally basic. I always find myself in need of a way to easily display a selection of posts from any combination post type or taxonomy. Hence, Flexible Post Widget.
|
15 |
|
16 |
Flexible Posts Widget (FPW) is more than just a simple alternative to the default Recent Posts widget. With many per-instance options it is highly customizable and allows advanced users to display the resulting posts virtually any way imaginable.
|
@@ -18,6 +19,7 @@ Flexible Posts Widget (FPW) is more than just a simple alternative to the defaul
|
|
18 |
Version 3.0 is a major enhancement as widgets can now get posts by *BOTH* post type and/or taxonomy & term as well as select *multiple* post types and terms. Previous versions of the plugin only allowed post type OR taxonomy & term queries, not both.
|
19 |
|
20 |
= Features & options =
|
|
|
21 |
* Customizable widget title
|
22 |
* Get posts via post type(s) and/or taxonomy & term(s).
|
23 |
* Control the number of posts displayed and the number of posts to offset.
|
@@ -26,17 +28,20 @@ Version 3.0 is a major enhancement as widgets can now get posts by *BOTH* post t
|
|
26 |
* Order posts by: date, ID, title, menu order, random; and sort posts: ascending or descending.
|
27 |
* Each widget's output can be customized by user-defined templates added to the current theme folder.
|
28 |
|
29 |
-
|
|
|
30 |
* English
|
31 |
* Spanish
|
32 |
|
33 |
|
34 |
== Installation ==
|
|
|
35 |
1. Upload the `flexible-posts-widget` folder to the `/wp-content/plugins/` directory.
|
36 |
1. Activate the plugin through the 'Plugins' menu in WordPress.
|
37 |
1. Go to 'Appearance' > 'Widgets' and place the widget into a sidebar to configure it.
|
38 |
|
39 |
= To use a custom HTML output template =
|
|
|
40 |
1. Create a folder called `flexible-posts-widget` in the root of your theme folder.
|
41 |
1. Copy `widget.php` from within the plugin's `views` folder into your theme's new `flexible-posts-widget` folder.
|
42 |
1. Optional: Rename your theme's `widget.php` template file to a name of your choice (to use different templates for each widget instance).
|
@@ -45,6 +50,7 @@ Version 3.0 is a major enhancement as widgets can now get posts by *BOTH* post t
|
|
45 |
|
46 |
|
47 |
== Frequently Asked Questions ==
|
|
|
48 |
= How can I display custom fields (custom meta values) with FPW? =
|
49 |
You'll want to create a custom HTML template by following [the instructions](http://wordpress.org/extend/plugins/flexible-posts-widget/installation/ "View instructions for creating custom FPW templates") and then you can use the standard WordPress [Custom Field](http://codex.wordpress.org/Custom_Fields "View custom field functions on the WordPress Codex") functions the same way you would if you were editing your theme's other template files.
|
50 |
|
@@ -58,14 +64,12 @@ FPW intentionally does NOT add any styling of it's own. To adjust the font size
|
|
58 |
= Does this plugin/widget insert any styles or scripts into my site? =
|
59 |
FPW does not add styles or scripts to your public theme. The plugin is intentionally designed to work within your existing theme. FPW does add one stylesheet and one JavaScript to the Widgets page in wp-admin to help with the administration of any FPWs in use.
|
60 |
|
61 |
-
= Want to add support for another language? =
|
62 |
-
I'd love to support more languages. Feel free to post PO & MO files for your language to a [new forum thread](http://wordpress.org/tags/flexible-posts-widget/) and I'll get them added to the plugin.
|
63 |
-
|
64 |
= Questions, Support & Bug Reports =
|
65 |
-
To get answers to your questions, request help or submit a bug report, please
|
66 |
|
67 |
|
68 |
== Screenshots ==
|
|
|
69 |
1. Configuring a Flexible Posts Widget in wp-admin with the Post Type tab displayed.
|
70 |
1. Configuring a Flexible Posts Widget in wp-admin with the Taxonomy & Term tab displayed.
|
71 |
1. An example of posts displayed using WordPress's TwentyTwelve theme and the default Feature Image (post-thumbnail) size. This demonstrates how the plugin looks out-of-the-box with no user-customized styling or output in a default theme.
|
@@ -74,14 +78,17 @@ To get answers to your questions, request help or submit a bug report, please st
|
|
74 |
1. In the wild: FPW displaying several posts over at http://chnl7700.mnsu.edu. Also highly customized output and theme styles.
|
75 |
|
76 |
== Upgrade Notice ==
|
|
|
77 |
When upgrading from one major version to another (version 1.x to version 2.x to version 3.x, etc), please remember to verify your settings for any existing widgets. Not all settings combinations will be saved after a major release upgrade.
|
78 |
|
79 |
|
80 |
== Other Notes ==
|
|
|
81 |
= Upgrading from one major version to another =
|
82 |
When upgrading between major releases (version 1.x to version 2.x to version 3.x, etc), please remember to verify your settings for any existing widgets. Not all settings combinations will be saved after a major release upgrade.
|
83 |
|
84 |
= Default vs. Custom Templates =
|
|
|
85 |
FPW comes with a default template for the widget output. If you would like to alter the widget display code, create a new folder called `flexible-posts-widget` in your template directory and copy over the "views/widget.php" file.
|
86 |
|
87 |
Edit the new file in your theme to your desired HTML layout. Please do not edit the one in the plugin folder as that will cause conflicts when you update the plugin to the latest release.
|
@@ -96,11 +103,8 @@ Edit the new file in your theme to your desired HTML layout. Please do not edit
|
|
96 |
|
97 |
== Changelog ==
|
98 |
|
99 |
-
= 3.1.1 =
|
100 |
-
* Fixed incorrect use of rtrim in getTemplateHierarchy when getting custom template files. (Props: @mortenf)
|
101 |
-
|
102 |
= 3.1 =
|
103 |
-
* Internationalized and added Spanish
|
104 |
* Added support for Media post types with "image/" mime types to be displayed directly in the default template.
|
105 |
|
106 |
= 3.0.2 =
|
@@ -110,6 +114,7 @@ Edit the new file in your theme to your desired HTML layout. Please do not edit
|
|
110 |
* Bug fix: Not able to get all registered post types & taxonomies until after widget init. Had to reorder some code.
|
111 |
* Bug fix: when getting post types for display in widget admin. (Props: @angelfish276)
|
112 |
|
|
|
113 |
= 3.0 =
|
114 |
* Allow widgets to query by post type and/or taxonomy & term instead of just one or the other. (Props: @vernal)
|
115 |
* Allow widgets to query by multiple post types and multiple terms within the same taxonomy. (Props: @vernal)
|
4 |
Tags: widget, widgets, posts, categories, tags, recent posts, thumbnails, custom post types, custom taxonomies, feature image
|
5 |
Requires at least: 3.2
|
6 |
Tested up to: 3.5.1
|
7 |
+
Stable tag: 3.1
|
8 |
License: GPL2 or later
|
9 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
10 |
|
11 |
An advanced posts display widget with many options. Display posts in your sidebars any way you'd like!
|
12 |
|
13 |
== Description ==
|
14 |
+
|
15 |
The default Recent Posts widget is exceptionally basic. I always find myself in need of a way to easily display a selection of posts from any combination post type or taxonomy. Hence, Flexible Post Widget.
|
16 |
|
17 |
Flexible Posts Widget (FPW) is more than just a simple alternative to the default Recent Posts widget. With many per-instance options it is highly customizable and allows advanced users to display the resulting posts virtually any way imaginable.
|
19 |
Version 3.0 is a major enhancement as widgets can now get posts by *BOTH* post type and/or taxonomy & term as well as select *multiple* post types and terms. Previous versions of the plugin only allowed post type OR taxonomy & term queries, not both.
|
20 |
|
21 |
= Features & options =
|
22 |
+
|
23 |
* Customizable widget title
|
24 |
* Get posts via post type(s) and/or taxonomy & term(s).
|
25 |
* Control the number of posts displayed and the number of posts to offset.
|
28 |
* Order posts by: date, ID, title, menu order, random; and sort posts: ascending or descending.
|
29 |
* Each widget's output can be customized by user-defined templates added to the current theme folder.
|
30 |
|
31 |
+
== Supported Languages =
|
32 |
+
|
33 |
* English
|
34 |
* Spanish
|
35 |
|
36 |
|
37 |
== Installation ==
|
38 |
+
|
39 |
1. Upload the `flexible-posts-widget` folder to the `/wp-content/plugins/` directory.
|
40 |
1. Activate the plugin through the 'Plugins' menu in WordPress.
|
41 |
1. Go to 'Appearance' > 'Widgets' and place the widget into a sidebar to configure it.
|
42 |
|
43 |
= To use a custom HTML output template =
|
44 |
+
|
45 |
1. Create a folder called `flexible-posts-widget` in the root of your theme folder.
|
46 |
1. Copy `widget.php` from within the plugin's `views` folder into your theme's new `flexible-posts-widget` folder.
|
47 |
1. Optional: Rename your theme's `widget.php` template file to a name of your choice (to use different templates for each widget instance).
|
50 |
|
51 |
|
52 |
== Frequently Asked Questions ==
|
53 |
+
|
54 |
= How can I display custom fields (custom meta values) with FPW? =
|
55 |
You'll want to create a custom HTML template by following [the instructions](http://wordpress.org/extend/plugins/flexible-posts-widget/installation/ "View instructions for creating custom FPW templates") and then you can use the standard WordPress [Custom Field](http://codex.wordpress.org/Custom_Fields "View custom field functions on the WordPress Codex") functions the same way you would if you were editing your theme's other template files.
|
56 |
|
64 |
= Does this plugin/widget insert any styles or scripts into my site? =
|
65 |
FPW does not add styles or scripts to your public theme. The plugin is intentionally designed to work within your existing theme. FPW does add one stylesheet and one JavaScript to the Widgets page in wp-admin to help with the administration of any FPWs in use.
|
66 |
|
|
|
|
|
|
|
67 |
= Questions, Support & Bug Reports =
|
68 |
+
To get answers to your questions, request help or submit a bug report, please visit the forum: http://wordpress.org/tags/flexible-posts-widget/
|
69 |
|
70 |
|
71 |
== Screenshots ==
|
72 |
+
|
73 |
1. Configuring a Flexible Posts Widget in wp-admin with the Post Type tab displayed.
|
74 |
1. Configuring a Flexible Posts Widget in wp-admin with the Taxonomy & Term tab displayed.
|
75 |
1. An example of posts displayed using WordPress's TwentyTwelve theme and the default Feature Image (post-thumbnail) size. This demonstrates how the plugin looks out-of-the-box with no user-customized styling or output in a default theme.
|
78 |
1. In the wild: FPW displaying several posts over at http://chnl7700.mnsu.edu. Also highly customized output and theme styles.
|
79 |
|
80 |
== Upgrade Notice ==
|
81 |
+
|
82 |
When upgrading from one major version to another (version 1.x to version 2.x to version 3.x, etc), please remember to verify your settings for any existing widgets. Not all settings combinations will be saved after a major release upgrade.
|
83 |
|
84 |
|
85 |
== Other Notes ==
|
86 |
+
|
87 |
= Upgrading from one major version to another =
|
88 |
When upgrading between major releases (version 1.x to version 2.x to version 3.x, etc), please remember to verify your settings for any existing widgets. Not all settings combinations will be saved after a major release upgrade.
|
89 |
|
90 |
= Default vs. Custom Templates =
|
91 |
+
|
92 |
FPW comes with a default template for the widget output. If you would like to alter the widget display code, create a new folder called `flexible-posts-widget` in your template directory and copy over the "views/widget.php" file.
|
93 |
|
94 |
Edit the new file in your theme to your desired HTML layout. Please do not edit the one in the plugin folder as that will cause conflicts when you update the plugin to the latest release.
|
103 |
|
104 |
== Changelog ==
|
105 |
|
|
|
|
|
|
|
106 |
= 3.1 =
|
107 |
+
* Internationalized and added Spanish. (Props: @elarequi)
|
108 |
* Added support for Media post types with "image/" mime types to be displayed directly in the default template.
|
109 |
|
110 |
= 3.0.2 =
|
114 |
* Bug fix: Not able to get all registered post types & taxonomies until after widget init. Had to reorder some code.
|
115 |
* Bug fix: when getting post types for display in widget admin. (Props: @angelfish276)
|
116 |
|
117 |
+
|
118 |
= 3.0 =
|
119 |
* Allow widgets to query by post type and/or taxonomy & term instead of just one or the other. (Props: @vernal)
|
120 |
* Allow widgets to query by multiple post types and multiple terms within the same taxonomy. (Props: @vernal)
|