Version Description
- 19/09/2015
Download this release
Release Info
Developer | satrya |
Plugin | Recent Posts Widget Extended |
Version | 0.9.9.3 |
Comparing to | |
See all releases |
Code changes from version 0.9.9.2 to 0.9.9.3
- classes/widget.php +6 -5
- includes/form.php +42 -35
- includes/functions.php +13 -7
- languages/rpwe.pot +57 -53
- readme.txt +14 -11
- rpwe.php +7 -5
classes/widget.php
CHANGED
@@ -21,7 +21,7 @@ class Recent_Posts_Widget_Extended extends WP_Widget {
|
|
21 |
/* Set up the widget options. */
|
22 |
$widget_options = array(
|
23 |
'classname' => 'rpwe_widget recent-posts-extended',
|
24 |
-
'description' => __( 'An advanced widget that gives you total control over the output of your site’s most recent Posts.', '
|
25 |
);
|
26 |
|
27 |
$control_options = array(
|
@@ -31,10 +31,10 @@ class Recent_Posts_Widget_Extended extends WP_Widget {
|
|
31 |
|
32 |
/* Create the widget. */
|
33 |
parent::__construct(
|
34 |
-
'rpwe_widget',
|
35 |
-
__( 'Recent Posts Extended', '
|
36 |
-
$widget_options,
|
37 |
-
$control_options
|
38 |
);
|
39 |
|
40 |
}
|
@@ -97,6 +97,7 @@ class Recent_Posts_Widget_Extended extends WP_Widget {
|
|
97 |
$instance['title_url'] = esc_url( $new_instance['title_url'] );
|
98 |
|
99 |
$instance['ignore_sticky'] = isset( $new_instance['ignore_sticky'] ) ? (bool) $new_instance['ignore_sticky'] : 0;
|
|
|
100 |
$instance['limit'] = (int)( $new_instance['limit'] );
|
101 |
$instance['offset'] = (int)( $new_instance['offset'] );
|
102 |
$instance['order'] = stripslashes( $new_instance['order'] );
|
21 |
/* Set up the widget options. */
|
22 |
$widget_options = array(
|
23 |
'classname' => 'rpwe_widget recent-posts-extended',
|
24 |
+
'description' => __( 'An advanced widget that gives you total control over the output of your site’s most recent Posts.', 'recent-posts-widget-extended' )
|
25 |
);
|
26 |
|
27 |
$control_options = array(
|
31 |
|
32 |
/* Create the widget. */
|
33 |
parent::__construct(
|
34 |
+
'rpwe_widget', // $this->id_base
|
35 |
+
__( 'Recent Posts Extended', 'recent-posts-widget-extended' ), // $this->name
|
36 |
+
$widget_options, // $this->widget_options
|
37 |
+
$control_options // $this->control_options
|
38 |
);
|
39 |
|
40 |
}
|
97 |
$instance['title_url'] = esc_url( $new_instance['title_url'] );
|
98 |
|
99 |
$instance['ignore_sticky'] = isset( $new_instance['ignore_sticky'] ) ? (bool) $new_instance['ignore_sticky'] : 0;
|
100 |
+
$instance['exclude_current'] = isset( $new_instance['exclude_current'] ) ? (bool) $new_instance['exclude_current'] : 0;
|
101 |
$instance['limit'] = (int)( $new_instance['limit'] );
|
102 |
$instance['offset'] = (int)( $new_instance['offset'] );
|
103 |
$instance['order'] = stripslashes( $new_instance['order'] );
|
includes/form.php
CHANGED
@@ -14,42 +14,42 @@
|
|
14 |
|
15 |
<p>
|
16 |
<label for="<?php echo $this->get_field_id( 'title' ); ?>">
|
17 |
-
<?php _e( 'Title', '
|
18 |
</label>
|
19 |
<input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr( $instance['title'] ); ?>" />
|
20 |
</p>
|
21 |
|
22 |
<p>
|
23 |
<label for="<?php echo $this->get_field_id( 'title_url' ); ?>">
|
24 |
-
<?php _e( 'Title URL', '
|
25 |
</label>
|
26 |
<input class="widefat" id="<?php echo $this->get_field_id( 'title_url' ); ?>" name="<?php echo $this->get_field_name( 'title_url' ); ?>" type="text" value="<?php echo esc_url( $instance['title_url'] ); ?>" />
|
27 |
</p>
|
28 |
|
29 |
<p>
|
30 |
<label for="<?php echo $this->get_field_id( 'cssID' ); ?>">
|
31 |
-
<?php _e( 'CSS ID', '
|
32 |
</label>
|
33 |
<input class="widefat" id="<?php echo $this->get_field_id( 'cssID' ); ?>" name="<?php echo $this->get_field_name( 'cssID' ); ?>" type="text" value="<?php echo sanitize_html_class( $instance['cssID'] ); ?>"/>
|
34 |
</p>
|
35 |
|
36 |
<p>
|
37 |
<label for="<?php echo $this->get_field_id( 'css_class' ); ?>">
|
38 |
-
<?php _e( 'CSS Class', '
|
39 |
</label>
|
40 |
<input class="widefat" id="<?php echo $this->get_field_id( 'css_class' ); ?>" name="<?php echo $this->get_field_name( 'css_class' ); ?>" type="text" value="<?php echo sanitize_html_class( $instance['css_class'] ); ?>"/>
|
41 |
</p>
|
42 |
|
43 |
<p>
|
44 |
<label for="<?php echo $this->get_field_id( 'before' ); ?>">
|
45 |
-
<?php _e( 'HTML or text before the recent posts', '
|
46 |
</label>
|
47 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'before' ); ?>" name="<?php echo $this->get_field_name( 'before' ); ?>" rows="5"><?php echo htmlspecialchars( stripslashes( $instance['before'] ) ); ?></textarea>
|
48 |
</p>
|
49 |
|
50 |
<p>
|
51 |
<label for="<?php echo $this->get_field_id( 'after' ); ?>">
|
52 |
-
<?php _e( 'HTML or text after the recent posts', '
|
53 |
</label>
|
54 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'after' ); ?>" name="<?php echo $this->get_field_name( 'after' ); ?>" rows="5"><?php echo htmlspecialchars( stripslashes( $instance['after'] ) ); ?></textarea>
|
55 |
</p>
|
@@ -61,13 +61,20 @@
|
|
61 |
<p>
|
62 |
<input class="checkbox" type="checkbox" <?php checked( $instance['ignore_sticky'], 1 ); ?> id="<?php echo $this->get_field_id( 'ignore_sticky' ); ?>" name="<?php echo $this->get_field_name( 'ignore_sticky' ); ?>" />
|
63 |
<label for="<?php echo $this->get_field_id( 'ignore_sticky' ); ?>">
|
64 |
-
<?php _e( 'Ignore sticky posts', '
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
65 |
</label>
|
66 |
</p>
|
67 |
|
68 |
<div class="rpwe-multiple-check-form">
|
69 |
<label>
|
70 |
-
<?php _e( 'Post Types', '
|
71 |
</label>
|
72 |
<ul>
|
73 |
<?php foreach ( get_post_types( array( 'public' => true ), 'objects' ) as $type ) : ?>
|
@@ -83,7 +90,7 @@
|
|
83 |
|
84 |
<p>
|
85 |
<label for="<?php echo $this->get_field_id( 'post_status' ); ?>">
|
86 |
-
<?php _e( 'Post Status', '
|
87 |
</label>
|
88 |
<select class="widefat" id="<?php echo $this->get_field_id( 'post_status' ); ?>" name="<?php echo $this->get_field_name( 'post_status' ); ?>" style="width:100%;">
|
89 |
<?php foreach ( get_available_post_statuses() as $status_value => $status_label ) { ?>
|
@@ -94,7 +101,7 @@
|
|
94 |
|
95 |
<p>
|
96 |
<label for="<?php echo $this->get_field_id( 'order' ); ?>">
|
97 |
-
<?php _e( 'Order', '
|
98 |
</label>
|
99 |
<select class="widefat" id="<?php echo $this->get_field_id( 'order' ); ?>" name="<?php echo $this->get_field_name( 'order' ); ?>" style="width:100%;">
|
100 |
<option value="DESC" <?php selected( $instance['order'], 'DESC' ); ?>><?php _e( 'Descending', 'rpwe' ) ?></option>
|
@@ -104,7 +111,7 @@
|
|
104 |
|
105 |
<p>
|
106 |
<label for="<?php echo $this->get_field_id( 'orderby' ); ?>">
|
107 |
-
<?php _e( 'Orderby', '
|
108 |
</label>
|
109 |
<select class="widefat" id="<?php echo $this->get_field_id( 'orderby' ); ?>" name="<?php echo $this->get_field_name( 'orderby' ); ?>" style="width:100%;">
|
110 |
<option value="ID" <?php selected( $instance['orderby'], 'ID' ); ?>><?php _e( 'ID', 'rpwe' ) ?></option>
|
@@ -120,7 +127,7 @@
|
|
120 |
|
121 |
<div class="rpwe-multiple-check-form">
|
122 |
<label>
|
123 |
-
<?php _e( 'Limit to Category', '
|
124 |
</label>
|
125 |
<ul>
|
126 |
<?php foreach ( rpwe_cats_list() as $category ) : ?>
|
@@ -136,7 +143,7 @@
|
|
136 |
|
137 |
<div class="rpwe-multiple-check-form">
|
138 |
<label>
|
139 |
-
<?php _e( 'Limit to Tag', '
|
140 |
</label>
|
141 |
<ul>
|
142 |
<?php foreach ( rpwe_tags_list() as $post_tag ) : ?>
|
@@ -152,7 +159,7 @@
|
|
152 |
|
153 |
<p>
|
154 |
<label for="<?php echo $this->get_field_id( 'taxonomy' ); ?>">
|
155 |
-
<?php _e( 'Limit to Taxonomy', '
|
156 |
</label>
|
157 |
<input type="text" class="widefat" id="<?php echo $this->get_field_id( 'taxonomy' ); ?>" name="<?php echo $this->get_field_name( 'taxonomy' ); ?>" value="<?php echo esc_attr( $instance['taxonomy'] ); ?>" />
|
158 |
<small><?php _e( 'Ex: category=1,2,4&post_tag=6,12', 'rpwe' );?><br />
|
@@ -165,17 +172,17 @@
|
|
165 |
|
166 |
<p>
|
167 |
<label for="<?php echo $this->get_field_id( 'limit' ); ?>">
|
168 |
-
<?php _e( 'Number of posts to show', '
|
169 |
</label>
|
170 |
<input class="widefat" id="<?php echo $this->get_field_id( 'limit' ); ?>" name="<?php echo $this->get_field_name( 'limit' ); ?>" type="number" step="1" min="-1" value="<?php echo (int)( $instance['limit'] ); ?>" />
|
171 |
</p>
|
172 |
|
173 |
<p>
|
174 |
<label for="<?php echo $this->get_field_id( 'offset' ); ?>">
|
175 |
-
<?php _e( 'Offset', '
|
176 |
</label>
|
177 |
<input class="widefat" id="<?php echo $this->get_field_id( 'offset' ); ?>" name="<?php echo $this->get_field_name( 'offset' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['offset'] ); ?>" />
|
178 |
-
<small><?php _e( 'The number of posts to skip', '
|
179 |
</p>
|
180 |
|
181 |
<?php if ( current_theme_supports( 'post-thumbnails' ) ) { ?>
|
@@ -183,29 +190,29 @@
|
|
183 |
<p>
|
184 |
<input id="<?php echo $this->get_field_id( 'thumb' ); ?>" name="<?php echo $this->get_field_name( 'thumb' ); ?>" type="checkbox" <?php checked( $instance['thumb'] ); ?> />
|
185 |
<label for="<?php echo $this->get_field_id( 'thumb' ); ?>">
|
186 |
-
<?php _e( 'Display Thumbnail', '
|
187 |
</label>
|
188 |
</p>
|
189 |
|
190 |
<p>
|
191 |
<label class="rpwe-block" for="<?php echo $this->get_field_id( 'thumb_height' ); ?>">
|
192 |
-
<?php _e( 'Thumbnail (height,width,align)', '
|
193 |
</label>
|
194 |
<input class= "small-input" id="<?php echo $this->get_field_id( 'thumb_height' ); ?>" name="<?php echo $this->get_field_name( 'thumb_height' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['thumb_height'] ); ?>" />
|
195 |
<input class="small-input" id="<?php echo $this->get_field_id( 'thumb_width' ); ?>" name="<?php echo $this->get_field_name( 'thumb_width' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['thumb_width'] ); ?>"/>
|
196 |
<select class="small-input" id="<?php echo $this->get_field_id( 'thumb_align' ); ?>" name="<?php echo $this->get_field_name( 'thumb_align' ); ?>">
|
197 |
-
<option value="rpwe-alignleft" <?php selected( $instance['thumb_align'], 'rpwe-alignleft' ); ?>><?php _e( 'Left', '
|
198 |
-
<option value="rpwe-alignright" <?php selected( $instance['thumb_align'], 'rpwe-alignright' ); ?>><?php _e( 'Right', '
|
199 |
-
<option value="rpwe-aligncenter" <?php selected( $instance['thumb_align'], 'rpwe-aligncenter' ); ?>><?php _e( 'Center', '
|
200 |
</select>
|
201 |
</p>
|
202 |
|
203 |
<p>
|
204 |
<label for="<?php echo $this->get_field_id( 'thumb_default' ); ?>">
|
205 |
-
<?php _e( 'Default Thumbnail', '
|
206 |
</label>
|
207 |
<input class="widefat" id="<?php echo $this->get_field_id( 'thumb_default' ); ?>" name="<?php echo $this->get_field_name( 'thumb_default' ); ?>" type="text" value="<?php echo $instance['thumb_default']; ?>"/>
|
208 |
-
<small><?php _e( 'Leave it blank to disable.', '
|
209 |
</p>
|
210 |
|
211 |
<?php } ?>
|
@@ -213,13 +220,13 @@
|
|
213 |
<p>
|
214 |
<input id="<?php echo $this->get_field_id( 'excerpt' ); ?>" name="<?php echo $this->get_field_name( 'excerpt' ); ?>" type="checkbox" <?php checked( $instance['excerpt'] ); ?> />
|
215 |
<label for="<?php echo $this->get_field_id( 'excerpt' ); ?>">
|
216 |
-
<?php _e( 'Display Excerpt', '
|
217 |
</label>
|
218 |
</p>
|
219 |
|
220 |
<p>
|
221 |
<label for="<?php echo $this->get_field_id( 'length' ); ?>">
|
222 |
-
<?php _e( 'Excerpt Length', '
|
223 |
</label>
|
224 |
<input class="widefat" id="<?php echo $this->get_field_id( 'length' ); ?>" name="<?php echo $this->get_field_name( 'length' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['length'] ); ?>" />
|
225 |
</p>
|
@@ -227,13 +234,13 @@
|
|
227 |
<p>
|
228 |
<input id="<?php echo $this->get_field_id( 'readmore' ); ?>" name="<?php echo $this->get_field_name( 'readmore' ); ?>" type="checkbox" <?php checked( $instance['readmore'] ); ?> />
|
229 |
<label for="<?php echo $this->get_field_id( 'readmore' ); ?>">
|
230 |
-
<?php _e( 'Display Readmore', '
|
231 |
</label>
|
232 |
</p>
|
233 |
|
234 |
<p>
|
235 |
<label for="<?php echo $this->get_field_id( 'readmore_text' ); ?>">
|
236 |
-
<?php _e( 'Readmore Text', '
|
237 |
</label>
|
238 |
<input class="widefat" id="<?php echo $this->get_field_id( 'readmore_text' ); ?>" name="<?php echo $this->get_field_name( 'readmore_text' ); ?>" type="text" value="<?php echo strip_tags( $instance['readmore_text'] ); ?>" />
|
239 |
</p>
|
@@ -241,28 +248,28 @@
|
|
241 |
<p>
|
242 |
<input id="<?php echo $this->get_field_id( 'comment_count' ); ?>" name="<?php echo $this->get_field_name( 'comment_count' ); ?>" type="checkbox" <?php checked( $instance['comment_count'] ); ?> />
|
243 |
<label for="<?php echo $this->get_field_id( 'comment_count' ); ?>">
|
244 |
-
<?php _e( 'Display Comment Count', '
|
245 |
</label>
|
246 |
</p>
|
247 |
|
248 |
<p>
|
249 |
<input id="<?php echo $this->get_field_id( 'date' ); ?>" name="<?php echo $this->get_field_name( 'date' ); ?>" type="checkbox" <?php checked( $instance['date'] ); ?> />
|
250 |
<label for="<?php echo $this->get_field_id( 'date' ); ?>">
|
251 |
-
<?php _e( 'Display Date', '
|
252 |
</label>
|
253 |
</p>
|
254 |
|
255 |
<p>
|
256 |
<input id="<?php echo $this->get_field_id( 'date_modified' ); ?>" name="<?php echo $this->get_field_name( 'date_modified' ); ?>" type="checkbox" <?php checked( $instance['date_modified'] ); ?> />
|
257 |
<label for="<?php echo $this->get_field_id( 'date_modified' ); ?>">
|
258 |
-
<?php _e( 'Display Modification Date', '
|
259 |
</label>
|
260 |
</p>
|
261 |
|
262 |
<p>
|
263 |
<input id="<?php echo $this->get_field_id( 'date_relative' ); ?>" name="<?php echo $this->get_field_name( 'date_relative' ); ?>" type="checkbox" <?php checked( $instance['date_relative'] ); ?> />
|
264 |
<label for="<?php echo $this->get_field_id( 'date_relative' ); ?>">
|
265 |
-
<?php _e( 'Use Relative Date. eg: 5 days ago', '
|
266 |
</label>
|
267 |
</p>
|
268 |
|
@@ -274,14 +281,14 @@
|
|
274 |
<p>
|
275 |
<input id="<?php echo $this->get_field_id( 'styles_default' ); ?>" name="<?php echo $this->get_field_name( 'styles_default' ); ?>" type="checkbox" <?php checked( $instance['styles_default'] ); ?> />
|
276 |
<label for="<?php echo $this->get_field_id( 'styles_default' ); ?>">
|
277 |
-
<?php _e( 'Use Default Styles', '
|
278 |
</label>
|
279 |
</p>
|
280 |
|
281 |
<p>
|
282 |
<label for="<?php echo $this->get_field_id( 'css' ); ?>">
|
283 |
-
<?php _e( 'Custom CSS', '
|
284 |
</label>
|
285 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'css' ); ?>" name="<?php echo $this->get_field_name( 'css' ); ?>" style="height:180px;"><?php echo $instance['css']; ?></textarea>
|
286 |
-
<small><?php _e( 'If you turn off the default styles, you can use these css code to customize the recent posts style.', '
|
287 |
</p>
|
14 |
|
15 |
<p>
|
16 |
<label for="<?php echo $this->get_field_id( 'title' ); ?>">
|
17 |
+
<?php _e( 'Title', 'recent-posts-widget-extended' ); ?>
|
18 |
</label>
|
19 |
<input class="widefat" id="<?php echo $this->get_field_id( 'title' ); ?>" name="<?php echo $this->get_field_name( 'title' ); ?>" type="text" value="<?php echo esc_attr( $instance['title'] ); ?>" />
|
20 |
</p>
|
21 |
|
22 |
<p>
|
23 |
<label for="<?php echo $this->get_field_id( 'title_url' ); ?>">
|
24 |
+
<?php _e( 'Title URL', 'recent-posts-widget-extended' ); ?>
|
25 |
</label>
|
26 |
<input class="widefat" id="<?php echo $this->get_field_id( 'title_url' ); ?>" name="<?php echo $this->get_field_name( 'title_url' ); ?>" type="text" value="<?php echo esc_url( $instance['title_url'] ); ?>" />
|
27 |
</p>
|
28 |
|
29 |
<p>
|
30 |
<label for="<?php echo $this->get_field_id( 'cssID' ); ?>">
|
31 |
+
<?php _e( 'CSS ID', 'recent-posts-widget-extended' ); ?>
|
32 |
</label>
|
33 |
<input class="widefat" id="<?php echo $this->get_field_id( 'cssID' ); ?>" name="<?php echo $this->get_field_name( 'cssID' ); ?>" type="text" value="<?php echo sanitize_html_class( $instance['cssID'] ); ?>"/>
|
34 |
</p>
|
35 |
|
36 |
<p>
|
37 |
<label for="<?php echo $this->get_field_id( 'css_class' ); ?>">
|
38 |
+
<?php _e( 'CSS Class', 'recent-posts-widget-extended' ); ?>
|
39 |
</label>
|
40 |
<input class="widefat" id="<?php echo $this->get_field_id( 'css_class' ); ?>" name="<?php echo $this->get_field_name( 'css_class' ); ?>" type="text" value="<?php echo sanitize_html_class( $instance['css_class'] ); ?>"/>
|
41 |
</p>
|
42 |
|
43 |
<p>
|
44 |
<label for="<?php echo $this->get_field_id( 'before' ); ?>">
|
45 |
+
<?php _e( 'HTML or text before the recent posts', 'recent-posts-widget-extended' );?>
|
46 |
</label>
|
47 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'before' ); ?>" name="<?php echo $this->get_field_name( 'before' ); ?>" rows="5"><?php echo htmlspecialchars( stripslashes( $instance['before'] ) ); ?></textarea>
|
48 |
</p>
|
49 |
|
50 |
<p>
|
51 |
<label for="<?php echo $this->get_field_id( 'after' ); ?>">
|
52 |
+
<?php _e( 'HTML or text after the recent posts', 'recent-posts-widget-extended' );?>
|
53 |
</label>
|
54 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'after' ); ?>" name="<?php echo $this->get_field_name( 'after' ); ?>" rows="5"><?php echo htmlspecialchars( stripslashes( $instance['after'] ) ); ?></textarea>
|
55 |
</p>
|
61 |
<p>
|
62 |
<input class="checkbox" type="checkbox" <?php checked( $instance['ignore_sticky'], 1 ); ?> id="<?php echo $this->get_field_id( 'ignore_sticky' ); ?>" name="<?php echo $this->get_field_name( 'ignore_sticky' ); ?>" />
|
63 |
<label for="<?php echo $this->get_field_id( 'ignore_sticky' ); ?>">
|
64 |
+
<?php _e( 'Ignore sticky posts', 'recent-posts-widget-extended' ); ?>
|
65 |
+
</label>
|
66 |
+
</p>
|
67 |
+
|
68 |
+
<p>
|
69 |
+
<input class="checkbox" type="checkbox" <?php checked( $instance['exclude_current'], 1 ); ?> id="<?php echo $this->get_field_id( 'exclude_current' ); ?>" name="<?php echo $this->get_field_name( 'exclude_current' ); ?>" />
|
70 |
+
<label for="<?php echo $this->get_field_id( 'exclude_current' ); ?>">
|
71 |
+
<?php _e( 'Exclude current post', 'recent-posts-widget-extended' ); ?>
|
72 |
</label>
|
73 |
</p>
|
74 |
|
75 |
<div class="rpwe-multiple-check-form">
|
76 |
<label>
|
77 |
+
<?php _e( 'Post Types', 'recent-posts-widget-extended' ); ?>
|
78 |
</label>
|
79 |
<ul>
|
80 |
<?php foreach ( get_post_types( array( 'public' => true ), 'objects' ) as $type ) : ?>
|
90 |
|
91 |
<p>
|
92 |
<label for="<?php echo $this->get_field_id( 'post_status' ); ?>">
|
93 |
+
<?php _e( 'Post Status', 'recent-posts-widget-extended' ); ?>
|
94 |
</label>
|
95 |
<select class="widefat" id="<?php echo $this->get_field_id( 'post_status' ); ?>" name="<?php echo $this->get_field_name( 'post_status' ); ?>" style="width:100%;">
|
96 |
<?php foreach ( get_available_post_statuses() as $status_value => $status_label ) { ?>
|
101 |
|
102 |
<p>
|
103 |
<label for="<?php echo $this->get_field_id( 'order' ); ?>">
|
104 |
+
<?php _e( 'Order', 'recent-posts-widget-extended' ); ?>
|
105 |
</label>
|
106 |
<select class="widefat" id="<?php echo $this->get_field_id( 'order' ); ?>" name="<?php echo $this->get_field_name( 'order' ); ?>" style="width:100%;">
|
107 |
<option value="DESC" <?php selected( $instance['order'], 'DESC' ); ?>><?php _e( 'Descending', 'rpwe' ) ?></option>
|
111 |
|
112 |
<p>
|
113 |
<label for="<?php echo $this->get_field_id( 'orderby' ); ?>">
|
114 |
+
<?php _e( 'Orderby', 'recent-posts-widget-extended' ); ?>
|
115 |
</label>
|
116 |
<select class="widefat" id="<?php echo $this->get_field_id( 'orderby' ); ?>" name="<?php echo $this->get_field_name( 'orderby' ); ?>" style="width:100%;">
|
117 |
<option value="ID" <?php selected( $instance['orderby'], 'ID' ); ?>><?php _e( 'ID', 'rpwe' ) ?></option>
|
127 |
|
128 |
<div class="rpwe-multiple-check-form">
|
129 |
<label>
|
130 |
+
<?php _e( 'Limit to Category', 'recent-posts-widget-extended' ); ?>
|
131 |
</label>
|
132 |
<ul>
|
133 |
<?php foreach ( rpwe_cats_list() as $category ) : ?>
|
143 |
|
144 |
<div class="rpwe-multiple-check-form">
|
145 |
<label>
|
146 |
+
<?php _e( 'Limit to Tag', 'recent-posts-widget-extended' ); ?>
|
147 |
</label>
|
148 |
<ul>
|
149 |
<?php foreach ( rpwe_tags_list() as $post_tag ) : ?>
|
159 |
|
160 |
<p>
|
161 |
<label for="<?php echo $this->get_field_id( 'taxonomy' ); ?>">
|
162 |
+
<?php _e( 'Limit to Taxonomy', 'recent-posts-widget-extended' ); ?>
|
163 |
</label>
|
164 |
<input type="text" class="widefat" id="<?php echo $this->get_field_id( 'taxonomy' ); ?>" name="<?php echo $this->get_field_name( 'taxonomy' ); ?>" value="<?php echo esc_attr( $instance['taxonomy'] ); ?>" />
|
165 |
<small><?php _e( 'Ex: category=1,2,4&post_tag=6,12', 'rpwe' );?><br />
|
172 |
|
173 |
<p>
|
174 |
<label for="<?php echo $this->get_field_id( 'limit' ); ?>">
|
175 |
+
<?php _e( 'Number of posts to show', 'recent-posts-widget-extended' ); ?>
|
176 |
</label>
|
177 |
<input class="widefat" id="<?php echo $this->get_field_id( 'limit' ); ?>" name="<?php echo $this->get_field_name( 'limit' ); ?>" type="number" step="1" min="-1" value="<?php echo (int)( $instance['limit'] ); ?>" />
|
178 |
</p>
|
179 |
|
180 |
<p>
|
181 |
<label for="<?php echo $this->get_field_id( 'offset' ); ?>">
|
182 |
+
<?php _e( 'Offset', 'recent-posts-widget-extended' ); ?>
|
183 |
</label>
|
184 |
<input class="widefat" id="<?php echo $this->get_field_id( 'offset' ); ?>" name="<?php echo $this->get_field_name( 'offset' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['offset'] ); ?>" />
|
185 |
+
<small><?php _e( 'The number of posts to skip', 'recent-posts-widget-extended' ); ?></small>
|
186 |
</p>
|
187 |
|
188 |
<?php if ( current_theme_supports( 'post-thumbnails' ) ) { ?>
|
190 |
<p>
|
191 |
<input id="<?php echo $this->get_field_id( 'thumb' ); ?>" name="<?php echo $this->get_field_name( 'thumb' ); ?>" type="checkbox" <?php checked( $instance['thumb'] ); ?> />
|
192 |
<label for="<?php echo $this->get_field_id( 'thumb' ); ?>">
|
193 |
+
<?php _e( 'Display Thumbnail', 'recent-posts-widget-extended' ); ?>
|
194 |
</label>
|
195 |
</p>
|
196 |
|
197 |
<p>
|
198 |
<label class="rpwe-block" for="<?php echo $this->get_field_id( 'thumb_height' ); ?>">
|
199 |
+
<?php _e( 'Thumbnail (height,width,align)', 'recent-posts-widget-extended' ); ?>
|
200 |
</label>
|
201 |
<input class= "small-input" id="<?php echo $this->get_field_id( 'thumb_height' ); ?>" name="<?php echo $this->get_field_name( 'thumb_height' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['thumb_height'] ); ?>" />
|
202 |
<input class="small-input" id="<?php echo $this->get_field_id( 'thumb_width' ); ?>" name="<?php echo $this->get_field_name( 'thumb_width' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['thumb_width'] ); ?>"/>
|
203 |
<select class="small-input" id="<?php echo $this->get_field_id( 'thumb_align' ); ?>" name="<?php echo $this->get_field_name( 'thumb_align' ); ?>">
|
204 |
+
<option value="rpwe-alignleft" <?php selected( $instance['thumb_align'], 'rpwe-alignleft' ); ?>><?php _e( 'Left', 'recent-posts-widget-extended' ) ?></option>
|
205 |
+
<option value="rpwe-alignright" <?php selected( $instance['thumb_align'], 'rpwe-alignright' ); ?>><?php _e( 'Right', 'recent-posts-widget-extended' ) ?></option>
|
206 |
+
<option value="rpwe-aligncenter" <?php selected( $instance['thumb_align'], 'rpwe-aligncenter' ); ?>><?php _e( 'Center', 'recent-posts-widget-extended' ) ?></option>
|
207 |
</select>
|
208 |
</p>
|
209 |
|
210 |
<p>
|
211 |
<label for="<?php echo $this->get_field_id( 'thumb_default' ); ?>">
|
212 |
+
<?php _e( 'Default Thumbnail', 'recent-posts-widget-extended' ); ?>
|
213 |
</label>
|
214 |
<input class="widefat" id="<?php echo $this->get_field_id( 'thumb_default' ); ?>" name="<?php echo $this->get_field_name( 'thumb_default' ); ?>" type="text" value="<?php echo $instance['thumb_default']; ?>"/>
|
215 |
+
<small><?php _e( 'Leave it blank to disable.', 'recent-posts-widget-extended' ); ?></small>
|
216 |
</p>
|
217 |
|
218 |
<?php } ?>
|
220 |
<p>
|
221 |
<input id="<?php echo $this->get_field_id( 'excerpt' ); ?>" name="<?php echo $this->get_field_name( 'excerpt' ); ?>" type="checkbox" <?php checked( $instance['excerpt'] ); ?> />
|
222 |
<label for="<?php echo $this->get_field_id( 'excerpt' ); ?>">
|
223 |
+
<?php _e( 'Display Excerpt', 'recent-posts-widget-extended' ); ?>
|
224 |
</label>
|
225 |
</p>
|
226 |
|
227 |
<p>
|
228 |
<label for="<?php echo $this->get_field_id( 'length' ); ?>">
|
229 |
+
<?php _e( 'Excerpt Length', 'recent-posts-widget-extended' ); ?>
|
230 |
</label>
|
231 |
<input class="widefat" id="<?php echo $this->get_field_id( 'length' ); ?>" name="<?php echo $this->get_field_name( 'length' ); ?>" type="number" step="1" min="0" value="<?php echo (int)( $instance['length'] ); ?>" />
|
232 |
</p>
|
234 |
<p>
|
235 |
<input id="<?php echo $this->get_field_id( 'readmore' ); ?>" name="<?php echo $this->get_field_name( 'readmore' ); ?>" type="checkbox" <?php checked( $instance['readmore'] ); ?> />
|
236 |
<label for="<?php echo $this->get_field_id( 'readmore' ); ?>">
|
237 |
+
<?php _e( 'Display Readmore', 'recent-posts-widget-extended' ); ?>
|
238 |
</label>
|
239 |
</p>
|
240 |
|
241 |
<p>
|
242 |
<label for="<?php echo $this->get_field_id( 'readmore_text' ); ?>">
|
243 |
+
<?php _e( 'Readmore Text', 'recent-posts-widget-extended' ); ?>
|
244 |
</label>
|
245 |
<input class="widefat" id="<?php echo $this->get_field_id( 'readmore_text' ); ?>" name="<?php echo $this->get_field_name( 'readmore_text' ); ?>" type="text" value="<?php echo strip_tags( $instance['readmore_text'] ); ?>" />
|
246 |
</p>
|
248 |
<p>
|
249 |
<input id="<?php echo $this->get_field_id( 'comment_count' ); ?>" name="<?php echo $this->get_field_name( 'comment_count' ); ?>" type="checkbox" <?php checked( $instance['comment_count'] ); ?> />
|
250 |
<label for="<?php echo $this->get_field_id( 'comment_count' ); ?>">
|
251 |
+
<?php _e( 'Display Comment Count', 'recent-posts-widget-extended' ); ?>
|
252 |
</label>
|
253 |
</p>
|
254 |
|
255 |
<p>
|
256 |
<input id="<?php echo $this->get_field_id( 'date' ); ?>" name="<?php echo $this->get_field_name( 'date' ); ?>" type="checkbox" <?php checked( $instance['date'] ); ?> />
|
257 |
<label for="<?php echo $this->get_field_id( 'date' ); ?>">
|
258 |
+
<?php _e( 'Display Date', 'recent-posts-widget-extended' ); ?>
|
259 |
</label>
|
260 |
</p>
|
261 |
|
262 |
<p>
|
263 |
<input id="<?php echo $this->get_field_id( 'date_modified' ); ?>" name="<?php echo $this->get_field_name( 'date_modified' ); ?>" type="checkbox" <?php checked( $instance['date_modified'] ); ?> />
|
264 |
<label for="<?php echo $this->get_field_id( 'date_modified' ); ?>">
|
265 |
+
<?php _e( 'Display Modification Date', 'recent-posts-widget-extended' ); ?>
|
266 |
</label>
|
267 |
</p>
|
268 |
|
269 |
<p>
|
270 |
<input id="<?php echo $this->get_field_id( 'date_relative' ); ?>" name="<?php echo $this->get_field_name( 'date_relative' ); ?>" type="checkbox" <?php checked( $instance['date_relative'] ); ?> />
|
271 |
<label for="<?php echo $this->get_field_id( 'date_relative' ); ?>">
|
272 |
+
<?php _e( 'Use Relative Date. eg: 5 days ago', 'recent-posts-widget-extended' ); ?>
|
273 |
</label>
|
274 |
</p>
|
275 |
|
281 |
<p>
|
282 |
<input id="<?php echo $this->get_field_id( 'styles_default' ); ?>" name="<?php echo $this->get_field_name( 'styles_default' ); ?>" type="checkbox" <?php checked( $instance['styles_default'] ); ?> />
|
283 |
<label for="<?php echo $this->get_field_id( 'styles_default' ); ?>">
|
284 |
+
<?php _e( 'Use Default Styles', 'recent-posts-widget-extended' ); ?>
|
285 |
</label>
|
286 |
</p>
|
287 |
|
288 |
<p>
|
289 |
<label for="<?php echo $this->get_field_id( 'css' ); ?>">
|
290 |
+
<?php _e( 'Custom CSS', 'recent-posts-widget-extended' ); ?>
|
291 |
</label>
|
292 |
<textarea class="widefat" id="<?php echo $this->get_field_id( 'css' ); ?>" name="<?php echo $this->get_field_name( 'css' ); ?>" style="height:180px;"><?php echo $instance['css']; ?></textarea>
|
293 |
+
<small><?php _e( 'If you turn off the default styles, you can use these css code to customize the recent posts style.', 'recent-posts-widget-extended' ); ?></small>
|
294 |
</p>
|
includes/functions.php
CHANGED
@@ -32,6 +32,7 @@ function rpwe_get_default_args() {
|
|
32 |
'post_type' => array( 'post' ),
|
33 |
'post_status' => 'publish',
|
34 |
'ignore_sticky' => 1,
|
|
|
35 |
|
36 |
'excerpt' => false,
|
37 |
'length' => 10,
|
@@ -44,7 +45,7 @@ function rpwe_get_default_args() {
|
|
44 |
'date_relative' => false,
|
45 |
'date_modified' => false,
|
46 |
'readmore' => false,
|
47 |
-
'readmore_text' => __( 'Read More »', '
|
48 |
'comment_count' => false,
|
49 |
|
50 |
'styles_default' => true,
|
@@ -166,29 +167,29 @@ function rpwe_get_recent_posts( $args = array() ) {
|
|
166 |
|
167 |
endif;
|
168 |
|
169 |
-
$html .= '<h3 class="rpwe-title"><a href="' . esc_url( get_permalink() ) . '" title="' . sprintf( esc_attr__( 'Permalink to %s', '
|
170 |
|
171 |
if ( $args['date'] ) :
|
172 |
$date = get_the_date();
|
173 |
if ( $args['date_relative'] ) :
|
174 |
-
$date = sprintf( __( '%s ago', '
|
175 |
endif;
|
176 |
$html .= '<time class="rpwe-time published" datetime="' . esc_html( get_the_date( 'c' ) ) . '">' . esc_html( $date ) . '</time>';
|
177 |
elseif ( $args['date_modified'] ) : // if both date functions are provided, we use date to be backwards compatible
|
178 |
$date = get_the_modified_date();
|
179 |
if ( $args['date_relative'] ) :
|
180 |
-
$date = sprintf( __( '%s ago', '
|
181 |
endif;
|
182 |
$html .= '<time class="rpwe-time modfied" datetime="' . esc_html( get_the_modified_date( 'c' ) ) . '">' . esc_html( $date ) . '</time>';
|
183 |
endif;
|
184 |
|
185 |
if ( $args['comment_count'] ) :
|
186 |
if ( get_comments_number() == 0 ) {
|
187 |
-
$comments = __( 'No Comments', '
|
188 |
} elseif ( get_comments_number() > 1 ) {
|
189 |
-
$comments = sprintf( __( '%s Comments', '
|
190 |
} else {
|
191 |
-
$comments = __( '1 Comment', '
|
192 |
}
|
193 |
$html .= '<a class="rpwe-comment comment-count" href="' . get_comments_link() . '">' . $comments . '</a>';
|
194 |
endif;
|
@@ -243,6 +244,11 @@ function rpwe_get_posts( $args = array() ) {
|
|
243 |
'ignore_sticky_posts' => $args['ignore_sticky'],
|
244 |
);
|
245 |
|
|
|
|
|
|
|
|
|
|
|
246 |
// Limit posts based on category.
|
247 |
if ( ! empty( $args['cat'] ) ) {
|
248 |
$query['category__in'] = $args['cat'];
|
32 |
'post_type' => array( 'post' ),
|
33 |
'post_status' => 'publish',
|
34 |
'ignore_sticky' => 1,
|
35 |
+
'exclude_current' => 1,
|
36 |
|
37 |
'excerpt' => false,
|
38 |
'length' => 10,
|
45 |
'date_relative' => false,
|
46 |
'date_modified' => false,
|
47 |
'readmore' => false,
|
48 |
+
'readmore_text' => __( 'Read More »', 'recent-posts-widget-extended' ),
|
49 |
'comment_count' => false,
|
50 |
|
51 |
'styles_default' => true,
|
167 |
|
168 |
endif;
|
169 |
|
170 |
+
$html .= '<h3 class="rpwe-title"><a href="' . esc_url( get_permalink() ) . '" title="' . sprintf( esc_attr__( 'Permalink to %s', 'recent-posts-widget-extended' ), the_title_attribute( 'echo=0' ) ) . '" rel="bookmark">' . esc_attr( get_the_title() ) . '</a></h3>';
|
171 |
|
172 |
if ( $args['date'] ) :
|
173 |
$date = get_the_date();
|
174 |
if ( $args['date_relative'] ) :
|
175 |
+
$date = sprintf( __( '%s ago', 'recent-posts-widget-extended' ), human_time_diff( get_the_date( 'U' ), current_time( 'timestamp' ) ) );
|
176 |
endif;
|
177 |
$html .= '<time class="rpwe-time published" datetime="' . esc_html( get_the_date( 'c' ) ) . '">' . esc_html( $date ) . '</time>';
|
178 |
elseif ( $args['date_modified'] ) : // if both date functions are provided, we use date to be backwards compatible
|
179 |
$date = get_the_modified_date();
|
180 |
if ( $args['date_relative'] ) :
|
181 |
+
$date = sprintf( __( '%s ago', 'recent-posts-widget-extended' ), human_time_diff( get_the_modified_date( 'U' ), current_time( 'timestamp' ) ) );
|
182 |
endif;
|
183 |
$html .= '<time class="rpwe-time modfied" datetime="' . esc_html( get_the_modified_date( 'c' ) ) . '">' . esc_html( $date ) . '</time>';
|
184 |
endif;
|
185 |
|
186 |
if ( $args['comment_count'] ) :
|
187 |
if ( get_comments_number() == 0 ) {
|
188 |
+
$comments = __( 'No Comments', 'recent-posts-widget-extended' );
|
189 |
} elseif ( get_comments_number() > 1 ) {
|
190 |
+
$comments = sprintf( __( '%s Comments', 'recent-posts-widget-extended' ), get_comments_number() );
|
191 |
} else {
|
192 |
+
$comments = __( '1 Comment', 'recent-posts-widget-extended' );
|
193 |
}
|
194 |
$html .= '<a class="rpwe-comment comment-count" href="' . get_comments_link() . '">' . $comments . '</a>';
|
195 |
endif;
|
244 |
'ignore_sticky_posts' => $args['ignore_sticky'],
|
245 |
);
|
246 |
|
247 |
+
// Exclude current post
|
248 |
+
if ( $args['exclude_current'] ) {
|
249 |
+
$query['post__not_in'] = array( get_the_ID() );
|
250 |
+
}
|
251 |
+
|
252 |
// Limit posts based on category.
|
253 |
if ( ! empty( $args['cat'] ) ) {
|
254 |
$query['category__in'] = $args['cat'];
|
languages/rpwe.pot
CHANGED
@@ -2,15 +2,15 @@
|
|
2 |
# This file is distributed under the same license as the Recent Posts Widget Extended package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
-
"Project-Id-Version: Recent Posts Widget Extended 0.9.9.
|
6 |
-
"Report-Msgid-Bugs-To:
|
7 |
-
"POT-Creation-Date: 2015-
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
11 |
"PO-Revision-Date: 2015-MO-DA HO:MI+ZONE\n"
|
12 |
-
"Last-Translator:
|
13 |
-
"Language-Team:
|
14 |
"X-Generator: grunt-wp-i18n 0.5.3\n"
|
15 |
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
16 |
"X-Poedit-Basepath: ..\n"
|
@@ -33,7 +33,7 @@ msgstr ""
|
|
33 |
msgid "Recent Posts Extended"
|
34 |
msgstr ""
|
35 |
|
36 |
-
#: includes/form.php:17 includes/form.php:
|
37 |
msgid "Title"
|
38 |
msgstr ""
|
39 |
|
@@ -61,159 +61,163 @@ msgstr ""
|
|
61 |
msgid "Ignore sticky posts"
|
62 |
msgstr ""
|
63 |
|
64 |
-
#: includes/form.php:
|
|
|
|
|
|
|
|
|
65 |
msgid "Post Types"
|
66 |
msgstr ""
|
67 |
|
68 |
-
#: includes/form.php:
|
69 |
msgid "Post Status"
|
70 |
msgstr ""
|
71 |
|
72 |
-
#: includes/form.php:
|
73 |
msgid "Order"
|
74 |
msgstr ""
|
75 |
|
76 |
-
#: includes/form.php:
|
77 |
msgid "Descending"
|
78 |
msgstr ""
|
79 |
|
80 |
-
#: includes/form.php:
|
81 |
msgid "Ascending"
|
82 |
msgstr ""
|
83 |
|
84 |
-
#: includes/form.php:
|
85 |
msgid "Orderby"
|
86 |
msgstr ""
|
87 |
|
88 |
-
#: includes/form.php:
|
89 |
msgid "ID"
|
90 |
msgstr ""
|
91 |
|
92 |
-
#: includes/form.php:
|
93 |
msgid "Author"
|
94 |
msgstr ""
|
95 |
|
96 |
-
#: includes/form.php:
|
97 |
msgid "Date"
|
98 |
msgstr ""
|
99 |
|
100 |
-
#: includes/form.php:
|
101 |
msgid "Modified"
|
102 |
msgstr ""
|
103 |
|
104 |
-
#: includes/form.php:
|
105 |
msgid "Random"
|
106 |
msgstr ""
|
107 |
|
108 |
-
#: includes/form.php:
|
109 |
msgid "Comment Count"
|
110 |
msgstr ""
|
111 |
|
112 |
-
#: includes/form.php:
|
113 |
msgid "Menu Order"
|
114 |
msgstr ""
|
115 |
|
116 |
-
#: includes/form.php:
|
117 |
msgid "Limit to Category"
|
118 |
msgstr ""
|
119 |
|
120 |
-
#: includes/form.php:
|
121 |
msgid "Limit to Tag"
|
122 |
msgstr ""
|
123 |
|
124 |
-
#: includes/form.php:
|
125 |
msgid "Limit to Taxonomy"
|
126 |
msgstr ""
|
127 |
|
128 |
-
#: includes/form.php:
|
129 |
msgid "Ex: category=1,2,4&post_tag=6,12"
|
130 |
msgstr ""
|
131 |
|
132 |
-
#: includes/form.php:
|
133 |
msgid "Available: "
|
134 |
msgstr ""
|
135 |
|
136 |
-
#: includes/form.php:
|
137 |
msgid "Number of posts to show"
|
138 |
msgstr ""
|
139 |
|
140 |
-
#: includes/form.php:
|
141 |
msgid "Offset"
|
142 |
msgstr ""
|
143 |
|
144 |
-
#: includes/form.php:
|
145 |
msgid "The number of posts to skip"
|
146 |
msgstr ""
|
147 |
|
148 |
-
#: includes/form.php:
|
149 |
msgid "Display Thumbnail"
|
150 |
msgstr ""
|
151 |
|
152 |
-
#: includes/form.php:
|
153 |
msgid "Thumbnail (height,width,align)"
|
154 |
msgstr ""
|
155 |
|
156 |
-
#: includes/form.php:
|
157 |
msgid "Left"
|
158 |
msgstr ""
|
159 |
|
160 |
-
#: includes/form.php:
|
161 |
msgid "Right"
|
162 |
msgstr ""
|
163 |
|
164 |
-
#: includes/form.php:
|
165 |
msgid "Center"
|
166 |
msgstr ""
|
167 |
|
168 |
-
#: includes/form.php:
|
169 |
msgid "Default Thumbnail"
|
170 |
msgstr ""
|
171 |
|
172 |
-
#: includes/form.php:
|
173 |
msgid "Leave it blank to disable."
|
174 |
msgstr ""
|
175 |
|
176 |
-
#: includes/form.php:
|
177 |
msgid "Display Excerpt"
|
178 |
msgstr ""
|
179 |
|
180 |
-
#: includes/form.php:
|
181 |
msgid "Excerpt Length"
|
182 |
msgstr ""
|
183 |
|
184 |
-
#: includes/form.php:
|
185 |
msgid "Display Readmore"
|
186 |
msgstr ""
|
187 |
|
188 |
-
#: includes/form.php:
|
189 |
msgid "Readmore Text"
|
190 |
msgstr ""
|
191 |
|
192 |
-
#: includes/form.php:
|
193 |
msgid "Display Comment Count"
|
194 |
msgstr ""
|
195 |
|
196 |
-
#: includes/form.php:
|
197 |
msgid "Display Date"
|
198 |
msgstr ""
|
199 |
|
200 |
-
#: includes/form.php:
|
201 |
msgid "Display Modification Date"
|
202 |
msgstr ""
|
203 |
|
204 |
-
#: includes/form.php:
|
205 |
msgid "Use Relative Date. eg: 5 days ago"
|
206 |
msgstr ""
|
207 |
|
208 |
-
#: includes/form.php:
|
209 |
msgid "Use Default Styles"
|
210 |
msgstr ""
|
211 |
|
212 |
-
#: includes/form.php:
|
213 |
msgid "Custom CSS"
|
214 |
msgstr ""
|
215 |
|
216 |
-
#: includes/form.php:
|
217 |
msgid ""
|
218 |
"If you turn off the default styles, you can use these css code to customize "
|
219 |
"the recent posts style."
|
@@ -223,27 +227,27 @@ msgstr ""
|
|
223 |
msgid "Recent Posts"
|
224 |
msgstr ""
|
225 |
|
226 |
-
#: includes/functions.php:
|
227 |
msgid "Read More »"
|
228 |
msgstr ""
|
229 |
|
230 |
-
#: includes/functions.php:
|
231 |
msgid "Permalink to %s"
|
232 |
msgstr ""
|
233 |
|
234 |
-
#: includes/functions.php:
|
235 |
msgid "%s ago"
|
236 |
msgstr ""
|
237 |
|
238 |
-
#: includes/functions.php:
|
239 |
msgid "No Comments"
|
240 |
msgstr ""
|
241 |
|
242 |
-
#: includes/functions.php:
|
243 |
msgid "%s Comments"
|
244 |
msgstr ""
|
245 |
|
246 |
-
#: includes/functions.php:
|
247 |
msgid "1 Comment"
|
248 |
msgstr ""
|
249 |
|
@@ -252,7 +256,7 @@ msgid "Recent Posts Widget Extended"
|
|
252 |
msgstr ""
|
253 |
|
254 |
#. Plugin URI of the plugin/theme
|
255 |
-
msgid "
|
256 |
msgstr ""
|
257 |
|
258 |
#. Description of the plugin/theme
|
@@ -266,5 +270,5 @@ msgid "Satrya"
|
|
266 |
msgstr ""
|
267 |
|
268 |
#. Author URI of the plugin/theme
|
269 |
-
msgid "
|
270 |
msgstr ""
|
2 |
# This file is distributed under the same license as the Recent Posts Widget Extended package.
|
3 |
msgid ""
|
4 |
msgstr ""
|
5 |
+
"Project-Id-Version: Recent Posts Widget Extended 0.9.9.3\n"
|
6 |
+
"Report-Msgid-Bugs-To: https://themephe.com/\n"
|
7 |
+
"POT-Creation-Date: 2015-09-19 14:47:10+00:00\n"
|
8 |
"MIME-Version: 1.0\n"
|
9 |
"Content-Type: text/plain; charset=utf-8\n"
|
10 |
"Content-Transfer-Encoding: 8bit\n"
|
11 |
"PO-Revision-Date: 2015-MO-DA HO:MI+ZONE\n"
|
12 |
+
"Last-Translator: ThemePhe (support@themephe.com)\n"
|
13 |
+
"Language-Team: ThemePhe (support@themephe.com)\n"
|
14 |
"X-Generator: grunt-wp-i18n 0.5.3\n"
|
15 |
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
16 |
"X-Poedit-Basepath: ..\n"
|
33 |
msgid "Recent Posts Extended"
|
34 |
msgstr ""
|
35 |
|
36 |
+
#: includes/form.php:17 includes/form.php:119
|
37 |
msgid "Title"
|
38 |
msgstr ""
|
39 |
|
61 |
msgid "Ignore sticky posts"
|
62 |
msgstr ""
|
63 |
|
64 |
+
#: includes/form.php:71
|
65 |
+
msgid "Exclude current post"
|
66 |
+
msgstr ""
|
67 |
+
|
68 |
+
#: includes/form.php:77
|
69 |
msgid "Post Types"
|
70 |
msgstr ""
|
71 |
|
72 |
+
#: includes/form.php:93
|
73 |
msgid "Post Status"
|
74 |
msgstr ""
|
75 |
|
76 |
+
#: includes/form.php:104
|
77 |
msgid "Order"
|
78 |
msgstr ""
|
79 |
|
80 |
+
#: includes/form.php:107
|
81 |
msgid "Descending"
|
82 |
msgstr ""
|
83 |
|
84 |
+
#: includes/form.php:108
|
85 |
msgid "Ascending"
|
86 |
msgstr ""
|
87 |
|
88 |
+
#: includes/form.php:114
|
89 |
msgid "Orderby"
|
90 |
msgstr ""
|
91 |
|
92 |
+
#: includes/form.php:117
|
93 |
msgid "ID"
|
94 |
msgstr ""
|
95 |
|
96 |
+
#: includes/form.php:118
|
97 |
msgid "Author"
|
98 |
msgstr ""
|
99 |
|
100 |
+
#: includes/form.php:120
|
101 |
msgid "Date"
|
102 |
msgstr ""
|
103 |
|
104 |
+
#: includes/form.php:121
|
105 |
msgid "Modified"
|
106 |
msgstr ""
|
107 |
|
108 |
+
#: includes/form.php:122
|
109 |
msgid "Random"
|
110 |
msgstr ""
|
111 |
|
112 |
+
#: includes/form.php:123
|
113 |
msgid "Comment Count"
|
114 |
msgstr ""
|
115 |
|
116 |
+
#: includes/form.php:124
|
117 |
msgid "Menu Order"
|
118 |
msgstr ""
|
119 |
|
120 |
+
#: includes/form.php:130
|
121 |
msgid "Limit to Category"
|
122 |
msgstr ""
|
123 |
|
124 |
+
#: includes/form.php:146
|
125 |
msgid "Limit to Tag"
|
126 |
msgstr ""
|
127 |
|
128 |
+
#: includes/form.php:162
|
129 |
msgid "Limit to Taxonomy"
|
130 |
msgstr ""
|
131 |
|
132 |
+
#: includes/form.php:165
|
133 |
msgid "Ex: category=1,2,4&post_tag=6,12"
|
134 |
msgstr ""
|
135 |
|
136 |
+
#: includes/form.php:166
|
137 |
msgid "Available: "
|
138 |
msgstr ""
|
139 |
|
140 |
+
#: includes/form.php:175
|
141 |
msgid "Number of posts to show"
|
142 |
msgstr ""
|
143 |
|
144 |
+
#: includes/form.php:182
|
145 |
msgid "Offset"
|
146 |
msgstr ""
|
147 |
|
148 |
+
#: includes/form.php:185
|
149 |
msgid "The number of posts to skip"
|
150 |
msgstr ""
|
151 |
|
152 |
+
#: includes/form.php:193
|
153 |
msgid "Display Thumbnail"
|
154 |
msgstr ""
|
155 |
|
156 |
+
#: includes/form.php:199
|
157 |
msgid "Thumbnail (height,width,align)"
|
158 |
msgstr ""
|
159 |
|
160 |
+
#: includes/form.php:204
|
161 |
msgid "Left"
|
162 |
msgstr ""
|
163 |
|
164 |
+
#: includes/form.php:205
|
165 |
msgid "Right"
|
166 |
msgstr ""
|
167 |
|
168 |
+
#: includes/form.php:206
|
169 |
msgid "Center"
|
170 |
msgstr ""
|
171 |
|
172 |
+
#: includes/form.php:212
|
173 |
msgid "Default Thumbnail"
|
174 |
msgstr ""
|
175 |
|
176 |
+
#: includes/form.php:215
|
177 |
msgid "Leave it blank to disable."
|
178 |
msgstr ""
|
179 |
|
180 |
+
#: includes/form.php:223
|
181 |
msgid "Display Excerpt"
|
182 |
msgstr ""
|
183 |
|
184 |
+
#: includes/form.php:229
|
185 |
msgid "Excerpt Length"
|
186 |
msgstr ""
|
187 |
|
188 |
+
#: includes/form.php:237
|
189 |
msgid "Display Readmore"
|
190 |
msgstr ""
|
191 |
|
192 |
+
#: includes/form.php:243
|
193 |
msgid "Readmore Text"
|
194 |
msgstr ""
|
195 |
|
196 |
+
#: includes/form.php:251
|
197 |
msgid "Display Comment Count"
|
198 |
msgstr ""
|
199 |
|
200 |
+
#: includes/form.php:258
|
201 |
msgid "Display Date"
|
202 |
msgstr ""
|
203 |
|
204 |
+
#: includes/form.php:265
|
205 |
msgid "Display Modification Date"
|
206 |
msgstr ""
|
207 |
|
208 |
+
#: includes/form.php:272
|
209 |
msgid "Use Relative Date. eg: 5 days ago"
|
210 |
msgstr ""
|
211 |
|
212 |
+
#: includes/form.php:284
|
213 |
msgid "Use Default Styles"
|
214 |
msgstr ""
|
215 |
|
216 |
+
#: includes/form.php:290
|
217 |
msgid "Custom CSS"
|
218 |
msgstr ""
|
219 |
|
220 |
+
#: includes/form.php:293
|
221 |
msgid ""
|
222 |
"If you turn off the default styles, you can use these css code to customize "
|
223 |
"the recent posts style."
|
227 |
msgid "Recent Posts"
|
228 |
msgstr ""
|
229 |
|
230 |
+
#: includes/functions.php:48
|
231 |
msgid "Read More »"
|
232 |
msgstr ""
|
233 |
|
234 |
+
#: includes/functions.php:170
|
235 |
msgid "Permalink to %s"
|
236 |
msgstr ""
|
237 |
|
238 |
+
#: includes/functions.php:175 includes/functions.php:181
|
239 |
msgid "%s ago"
|
240 |
msgstr ""
|
241 |
|
242 |
+
#: includes/functions.php:188
|
243 |
msgid "No Comments"
|
244 |
msgstr ""
|
245 |
|
246 |
+
#: includes/functions.php:190
|
247 |
msgid "%s Comments"
|
248 |
msgstr ""
|
249 |
|
250 |
+
#: includes/functions.php:192
|
251 |
msgid "1 Comment"
|
252 |
msgstr ""
|
253 |
|
256 |
msgstr ""
|
257 |
|
258 |
#. Plugin URI of the plugin/theme
|
259 |
+
msgid "https://themephe.com/items/recent-posts-widget-extended/"
|
260 |
msgstr ""
|
261 |
|
262 |
#. Description of the plugin/theme
|
270 |
msgstr ""
|
271 |
|
272 |
#. Author URI of the plugin/theme
|
273 |
+
msgid "https://themephe.com/"
|
274 |
msgstr ""
|
readme.txt
CHANGED
@@ -1,9 +1,9 @@
|
|
1 |
=== Recent Posts Widget Extended ===
|
2 |
-
Contributors: satrya,
|
3 |
Tags: recent posts, random posts, popular posts, thumbnails, widget, widgets, sidebar, excerpt, category, post tag, taxonomy, post type, post status, shortcode, multiple widgets
|
4 |
-
Requires at least: 3.
|
5 |
-
Tested up to: 4.3
|
6 |
-
Stable tag: 0.9.9.
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
@@ -11,18 +11,17 @@ Provides flexible and advanced recent posts. Display it via shortcode or widget
|
|
11 |
|
12 |
== Description ==
|
13 |
|
14 |
-
> Recent Posts Widget Extended version 1.0.0 will have some major updates like moving custom css to a file, rework the shortcode function, add exclude post option, etc. I hope the updates will be ready before September 1, please note, if you see an update from this plugin to **version 1.0.0** please backup your website before updating. Thank you for using my plugin. Have a nice day 😀
|
15 |
-
|
16 |
This plugin will enable a custom, flexible and super advanced recent posts, you can display it via shortcode or widget. Allows you to display a list of the most recent posts with thumbnail, excerpt and post date, also you can display it from all or specific or multiple taxonomy, post type and much more!
|
17 |
|
18 |
= New Features =
|
19 |
|
20 |
* Display modification date
|
21 |
* Display comment count
|
|
|
22 |
|
23 |
= Features Include =
|
24 |
|
25 |
-
* WordPress 4.3 Support.
|
26 |
* Shortcode feature. Please read [Other Notes](http://wordpress.org/plugins/recent-posts-widget-extended/other_notes)
|
27 |
* Taxonomy support!
|
28 |
* Post status option.
|
@@ -46,17 +45,17 @@ This plugin will enable a custom, flexible and super advanced recent posts, you
|
|
46 |
* English
|
47 |
* France
|
48 |
* Brazilian Portuguese
|
49 |
-
* [Contribute to your language](https://github.com/
|
50 |
|
51 |
= Support =
|
52 |
|
53 |
* [Forum support](http://wordpress.org/support/plugin/recent-posts-widget-extended).
|
54 |
* [Rate/Review the plugin](http://wordpress.org/support/view/plugin-reviews/recent-posts-widget-extended).
|
55 |
-
* [Submit translation](https://github.com/
|
56 |
|
57 |
= Plugin Info =
|
58 |
-
* Developed by [
|
59 |
-
* Check out the [Github](https://github.com/
|
60 |
|
61 |
= Contributors =
|
62 |
* [David Kryzaniak](http://profiles.wordpress.org/davidkryzaniak/)
|
@@ -256,6 +255,10 @@ after=""
|
|
256 |
|
257 |
> Recent Posts Widget Extended version 1.0.0 will have some major updates like moving custom css to a file, rework the shortcode function, add exclude post option, etc. I hope the updates will be ready before September 1, please note, if you see an update from this plugin to **version 1.0.0** please backup your website before updating. Thank you for using my plugin. Have a nice day 😀
|
258 |
|
|
|
|
|
|
|
|
|
259 |
= 0.9.9.2 - 13/08/2015 =
|
260 |
- **Add:** Brazilian portuguese translation. Props [Gil Barbara](https://github.com/gilbarbara)
|
261 |
- **Add:** Option to show modification date. Props [kurt-hectic](https://github.com/kurt-hectic)
|
1 |
=== Recent Posts Widget Extended ===
|
2 |
+
Contributors: satrya, themephe
|
3 |
Tags: recent posts, random posts, popular posts, thumbnails, widget, widgets, sidebar, excerpt, category, post tag, taxonomy, post type, post status, shortcode, multiple widgets
|
4 |
+
Requires at least: 3.9
|
5 |
+
Tested up to: 4.3.1
|
6 |
+
Stable tag: 0.9.9.3
|
7 |
License: GPLv2 or later
|
8 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
9 |
|
11 |
|
12 |
== Description ==
|
13 |
|
|
|
|
|
14 |
This plugin will enable a custom, flexible and super advanced recent posts, you can display it via shortcode or widget. Allows you to display a list of the most recent posts with thumbnail, excerpt and post date, also you can display it from all or specific or multiple taxonomy, post type and much more!
|
15 |
|
16 |
= New Features =
|
17 |
|
18 |
* Display modification date
|
19 |
* Display comment count
|
20 |
+
* Exclude current post
|
21 |
|
22 |
= Features Include =
|
23 |
|
24 |
+
* WordPress 4.3.1 Support.
|
25 |
* Shortcode feature. Please read [Other Notes](http://wordpress.org/plugins/recent-posts-widget-extended/other_notes)
|
26 |
* Taxonomy support!
|
27 |
* Post status option.
|
45 |
* English
|
46 |
* France
|
47 |
* Brazilian Portuguese
|
48 |
+
* [Contribute to your language](https://github.com/themephe/recent-posts-widget-extended/issues)
|
49 |
|
50 |
= Support =
|
51 |
|
52 |
* [Forum support](http://wordpress.org/support/plugin/recent-posts-widget-extended).
|
53 |
* [Rate/Review the plugin](http://wordpress.org/support/view/plugin-reviews/recent-posts-widget-extended).
|
54 |
+
* [Submit translation](https://github.com/themephe/recent-posts-widget-extended/issues).
|
55 |
|
56 |
= Plugin Info =
|
57 |
+
* Developed by [ThemePhe](https://themephe.com/)
|
58 |
+
* Check out the [Github](https://github.com/themephe/recent-posts-widget-extended) repo to contribute.
|
59 |
|
60 |
= Contributors =
|
61 |
* [David Kryzaniak](http://profiles.wordpress.org/davidkryzaniak/)
|
255 |
|
256 |
> Recent Posts Widget Extended version 1.0.0 will have some major updates like moving custom css to a file, rework the shortcode function, add exclude post option, etc. I hope the updates will be ready before September 1, please note, if you see an update from this plugin to **version 1.0.0** please backup your website before updating. Thank you for using my plugin. Have a nice day 😀
|
257 |
|
258 |
+
= 0.9.9.3 - 19/09/2015 =
|
259 |
+
- Change text-domain to matches the plugin slug
|
260 |
+
- **Add:** Exclude post option
|
261 |
+
|
262 |
= 0.9.9.2 - 13/08/2015 =
|
263 |
- **Add:** Brazilian portuguese translation. Props [Gil Barbara](https://github.com/gilbarbara)
|
264 |
- **Add:** Option to show modification date. Props [kurt-hectic](https://github.com/kurt-hectic)
|
rpwe.php
CHANGED
@@ -1,12 +1,14 @@
|
|
1 |
<?php
|
2 |
/**
|
3 |
* Plugin Name: Recent Posts Widget Extended
|
4 |
-
* Plugin URI:
|
5 |
* Description: Enables advanced widget that gives you total control over the output of your site’s most recent Posts.
|
6 |
-
* Version: 0.9.9.
|
7 |
* Author: Satrya
|
8 |
-
* Author URI:
|
9 |
-
* Author Email: satrya@
|
|
|
|
|
10 |
*
|
11 |
* This program is free software; you can redistribute it and/or modify it under the terms of the GNU
|
12 |
* General Public License as published by the Free Software Foundation; either version 2 of the License,
|
@@ -87,7 +89,7 @@ class RPW_Extended {
|
|
87 |
* @since 0.1
|
88 |
*/
|
89 |
public function i18n() {
|
90 |
-
load_plugin_textdomain( '
|
91 |
}
|
92 |
|
93 |
/**
|
1 |
<?php
|
2 |
/**
|
3 |
* Plugin Name: Recent Posts Widget Extended
|
4 |
+
* Plugin URI: https://themephe.com/items/recent-posts-widget-extended/
|
5 |
* Description: Enables advanced widget that gives you total control over the output of your site’s most recent Posts.
|
6 |
+
* Version: 0.9.9.3
|
7 |
* Author: Satrya
|
8 |
+
* Author URI: https://themephe.com/
|
9 |
+
* Author Email: satrya@themephe.com
|
10 |
+
* Text Domain: recent-posts-widget-extended
|
11 |
+
* Domain Path: /languages
|
12 |
*
|
13 |
* This program is free software; you can redistribute it and/or modify it under the terms of the GNU
|
14 |
* General Public License as published by the Free Software Foundation; either version 2 of the License,
|
89 |
* @since 0.1
|
90 |
*/
|
91 |
public function i18n() {
|
92 |
+
load_plugin_textdomain( 'recent-posts-widget-extended', false, dirname( plugin_basename( __FILE__ ) ) . '/languages/' );
|
93 |
}
|
94 |
|
95 |
/**
|