Newpost Catch - Version 1.3.12

Version Description

Download this release

Release Info

Developer s56bouya
Plugin Icon wp plugin Newpost Catch
Version 1.3.12
Comparing to
See all releases

Code changes from version 1.3.5 to 1.3.12

Files changed (4) hide show
  1. class.php +140 -119
  2. newpost-catch.php +2 -2
  3. readme.txt +7 -132
  4. style.css +8 -9
class.php CHANGED
@@ -18,10 +18,11 @@ if ( !class_exists('NewpostCatch') ) {
18
  if ( empty($this->pluginDir) ) $this->pluginDir = WP_PLUGIN_URL . '/newpost-catch';
19
 
20
  // default thumbnail
21
- $this->default_thumbnail = apply_filters('npc_thumb', $this->pluginDir . '/no_thumb.png' );
22
 
23
  // print stylesheet
24
- add_action( 'get_header', array( &$this, 'enqueue_stylesheet' ) );
 
25
 
26
  // activate textdomain for translations
27
  add_action( 'init', array( &$this, 'NewpostCatch_textdomain') );
@@ -40,8 +41,9 @@ if ( !class_exists('NewpostCatch') ) {
40
  foreach( $options as $key => $val ) {
41
  $options[$key] = $val['css']['active'];
42
  }
 
43
  if( in_array('1' , $options) ){
44
- $css_path = plugins_url('newpost-catch/style.css');
45
  } else {
46
  $css_path = ( @file_exists( STYLESHEETPATH.'/css/newpost-catch.css' ) ) ? get_stylesheet_directory_uri() . '/css/newpost-catch.css' : '' ;
47
  }
@@ -90,49 +92,63 @@ if ( !class_exists('NewpostCatch') ) {
90
 
91
  $sticky_posts = get_option( 'sticky_posts' );
92
 
93
- $npc_args = array(
94
- 'post_type' => $post_type,
95
- 'post_status' => 'publish',
96
- 'cat' => $cat,
97
- 'posts_per_page' => $number,
98
- 'orderby' => 'date',
99
- 'order' => 'DESC'
100
- );
101
-
102
- //先頭に固定表示している場合
103
- if( ! empty( $sticky_posts ) ){
104
- $npc_args['ignore_sticky_posts'] = 0;
105
- if( empty( $ignore )){
106
- $npc_args['post__not_in'] = $sticky_posts;
107
- }
108
  }
109
-
110
- $npc_query = new WP_Query( $npc_args );
111
- ?>
112
- <ul id="npcatch">
113
- <?php
114
- if( $npc_query->have_posts() ) :
115
- while( $npc_query->have_posts() ) : $npc_query->the_post();
116
- $date = ( isset( $instance['date']['active'] ) && $instance['date']['active'] == 1 ) ? '<span class="date">' . get_the_time( get_option('date_format') ) . '</span>' : '';
117
-
118
- if( has_post_thumbnail() ) {
119
- $thumb_id = get_post_thumbnail_id();
120
- $thumb_url = wp_get_attachment_image_src($thumb_id);
121
- $thumb_url = $thumb_url[0];
122
- } else {
123
- $thumb_url = $this->no_thumb_image();
124
  }
125
- ?>
126
- <li><a href="<?php echo esc_url( get_permalink() ); ?>" title="<?php esc_attr( the_title() ); ?>"><img src="<?php echo esc_url( $thumb_url ); ?>" width="<?php echo esc_attr( $width ); ?>" height="<?php echo esc_attr( $height ); ?>" alt="<?php the_title(); ?>" title="<?php the_title(); ?>"/><span class="title"><?php the_title(); echo $date; ?></span></a></li>
127
- <?php
128
- endwhile;
129
- else :
130
- ?>
131
- <p>no post</p>
132
- <?php endif; wp_reset_postdata(); ?>
133
- </ul>
134
 
135
- <?php
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
136
  echo $after_widget;
137
  }
138
 
@@ -168,79 +184,78 @@ if ( !class_exists('NewpostCatch') ) {
168
 
169
  // define default value
170
  $defaults = array(
171
- 'title' => __('LatestPost(s)' , 'newpost-catch'),
172
- 'width' => 10,
173
- 'height' => 10,
174
- 'number' => 5,
175
- 'date' => array( 'active' => false ),
176
- 'ignore_check' => array( 'active' => false ),
177
- 'css' => array( 'active' => true ),
178
- 'cat' => NULL,
179
- 'post_type' => 'post',
180
- );
181
 
182
  $instance = wp_parse_args( (array) $instance, $defaults );
183
- ?>
184
- <p>
185
- <label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title' , 'newpost-catch'); ?></label>
186
- <input id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" class="widefat" value="<?php echo esc_attr($instance['title']); ?>" />
187
- </p>
188
- <p>
189
- <?php _e('Thumbnail Size' , 'newpost-catch'); ?><br />
190
- <label for="<?php echo $this->get_field_id('width'); ?>"><?php _e('Width' , 'newpost-catch'); ?></label>
191
- <input id="<?php echo $this->get_field_id('width'); ?>" name="<?php echo $this->get_field_name( 'width' ); ?>" type="text" style="width:50px" value="<?php echo esc_attr($instance['width']); ?>" /> px
192
- <br />
193
- <label for="<?php echo $this->get_field_id('height'); ?>"><?php _e('Height' , 'newpost-catch'); ?></label>
194
- <input id="<?php echo $this->get_field_id('height'); ?>" name="<?php echo $this->get_field_name('height'); ?>" type="text" style="width:50px;" value="<?php echo esc_attr($instance['height']); ?>" /> px
195
- </p>
196
- <p>
197
- <label for="<?php echo $this->get_field_id('number'); ?>"><?php _e('Show post(s)' , 'newpost-catch'); ?></label>
198
- <input style="width:30px;" id="<?php echo $this->get_field_id('number'); ?>" name="<?php echo $this->get_field_name('number'); ?>" type="text" value="<?php echo esc_attr($instance['number']); ?>" /> <?php _e('Post(s)', 'newpost-catch'); ?>
199
- </p>
200
- <p>
201
- <input type="checkbox" class="checkbox" value='1' <?php echo ($instance['date']['active']) ? 'checked="checked"' : ''; ?> id="<?php echo $this->get_field_id( 'date' ); ?>" name="<?php echo $this->get_field_name( 'date' ); ?>" /> <label for="<?php echo $this->get_field_id( 'date' ); ?>"><?php _e('Display date', 'newpost-catch'); ?></label>
202
- </p>
203
- <p>
204
- <input type="checkbox" class="checkbox" value='1' <?php echo ($instance['ignore_check']['active']) ? 'checked="checked"' : ''; ?> id="<?php echo $this->get_field_id( 'ignore_check' ); ?>" name="<?php echo $this->get_field_name( 'ignore_check' ); ?>" /> <label for="<?php echo $this->get_field_id( 'ignore_check' ); ?>"><?php _e('Display sticky post', 'newpost-catch'); ?></label>
205
- </p>
206
- <p>
207
- <input type="checkbox" class="checkbox" value='1' <?php if($instance['css']['active']){ echo 'checked="checked"'; } else { echo ''; } ?> id="<?php echo $this->get_field_id( 'css' ); ?>" name="<?php echo $this->get_field_name( 'css' ); ?>" /> <label for="<?php echo $this->get_field_id( 'css' ); ?>"><?php _e('Use default css', 'newpost-catch'); ?></label>
208
- </p>
209
  <?php _e('Post types' , 'newpost-catch'); ?><br />
210
- <?php
211
- $args = array(
212
- 'public' => true,
213
- );
214
-
215
- $output = 'objects';
216
- $operator = 'and';
217
-
218
- $post_types = get_post_types( $args, $output, $operator );
219
- foreach ( $post_types as $post_type ) {
220
- if( $post_type->name !== 'attachment' ){
221
- ?>
222
- <p><input type="radio" id="<?php echo $this->get_field_name($post_type->name); ?>" name="<?php echo $this->get_field_name('post_type'); ?>" value="<?php echo $post_type->name; ?>" <?php echo ( $instance['post_type'] == $post_type->name ) ? 'checked="checked"' : ''; ?> > <label for="<?php echo $this->get_field_name($post_type->name); ?>"><?php echo $post_type->labels->singular_name . '(' . $post_type->name . ')'; ?></label></p>
223
- <?php
224
- }
225
- }
226
- ?>
227
- <?php if( $instance['post_type'] == 'post' ){ ?>
228
- <p>
229
- <label for="<?php echo $this->get_field_id('cat'); ?>"><?php _e('Display category(ies)' , 'newpost-catch'); ?></label>
230
- <input id="<?php echo $this->get_field_id('cat'); ?>" name="<?php echo $this->get_field_name('cat'); ?>" type="text" class="widefat" value="<?php echo esc_attr($instance['cat']); ?>" />
231
- <span><a href="<?php echo get_bloginfo('url') . '/wp-admin/edit-tags.php?taxonomy=category'; ?>"><?php _e('Check the category ID' , 'newpost-catch'); ?></a></span>
232
- </p>
233
- <?php } ?>
234
- <p>
235
- <?php _e('Use shortcode' , 'newpost-catch'); ?>
236
- <?php _e('Can use the shortcode in a textwidget and theme files.' , 'newpost-catch'); ?> <a href="http://wordpress.org/plugins/newpost-catch/faq/" target="_blank">FAQ</a>
237
- </p>
238
- <p>
239
- <?php _e('Contact/Follow' , 'newpost-catch'); ?>
240
- <a href="https://twitter.com/NewpostCatch" target="_blank">Twitter</a>
241
- <a href="https://www.facebook.com/NewpostCatch" target="_blank">Facebook</a>
242
- </p>
243
- <?php
244
  }
245
  }
246
  }
@@ -307,7 +322,7 @@ if ( !class_exists( 'NewpostCatch_SC' ) ) {
307
  while( $npc_sc_query->have_posts() ) :
308
  $npc_sc_query->the_post();
309
 
310
- $get_date = ( $date == true ) ? '<span class="date">' . esc_html( get_the_time( get_option('date_format') ) ) . '</span>' : '';
311
 
312
  $thumb_url = '';
313
  if( has_post_thumbnail( get_the_ID() ) ) {
@@ -318,10 +333,16 @@ if ( !class_exists( 'NewpostCatch_SC' ) ) {
318
  $thumb_url = $npc_construct->no_thumb_image();
319
  }
320
 
321
- $html .= '<li><a href="' . esc_url( get_permalink() ) . '" title="' . get_the_title() . '">';
322
- $html .= '<img src="' . esc_url( $thumb_url ) . '" width="' . esc_attr( $width ) . '" height="' . esc_attr( $height ) . '" alt="' . get_the_title() . '" title="' . get_the_title() . '" /></a>';
323
- $html .= '<span class="title"><a href="' . esc_url( get_permalink() ) . '" title="' . get_the_title() . '">' . get_the_title() . $get_date;
324
- $html .= '</a></span></li>';
 
 
 
 
 
 
325
  endwhile;
326
  $html .= '</ul>';
327
  endif;
@@ -330,4 +351,4 @@ if ( !class_exists( 'NewpostCatch_SC' ) ) {
330
  return $html;
331
  }
332
  }
333
- }
18
  if ( empty($this->pluginDir) ) $this->pluginDir = WP_PLUGIN_URL . '/newpost-catch';
19
 
20
  // default thumbnail
21
+ $this->default_thumbnail = apply_filters( 'npc_thumb', $this->pluginDir . '/no_thumb.png' );
22
 
23
  // print stylesheet
24
+ // add_action( 'get_header', array( &$this, 'enqueue_stylesheet' ) );
25
+ add_action( 'wp_enqueue_scripts', array( &$this, 'enqueue_stylesheet' ) );
26
 
27
  // activate textdomain for translations
28
  add_action( 'init', array( &$this, 'NewpostCatch_textdomain') );
41
  foreach( $options as $key => $val ) {
42
  $options[$key] = $val['css']['active'];
43
  }
44
+
45
  if( in_array('1' , $options) ){
46
+ $css_path = plugins_url(basename( rtrim(dirname(__FILE__), '/') ) . '/style.css');
47
  } else {
48
  $css_path = ( @file_exists( STYLESHEETPATH.'/css/newpost-catch.css' ) ) ? get_stylesheet_directory_uri() . '/css/newpost-catch.css' : '' ;
49
  }
92
 
93
  $sticky_posts = get_option( 'sticky_posts' );
94
 
95
+ $npc_args = array(
96
+ 'post_type' => $post_type,
97
+ 'post_status' => 'publish',
98
+ 'cat' => $cat,
99
+ 'posts_per_page' => $number,
100
+ 'orderby' => 'date',
101
+ 'order' => 'DESC'
102
+ );
103
+
104
+ //先頭に固定表示している場合
105
+ if( ! empty( $sticky_posts ) ){
106
+ $npc_args['ignore_sticky_posts'] = 0;
107
+ if( empty( $ignore )){
108
+ $npc_args['post__not_in'] = $sticky_posts;
 
109
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
110
  }
 
 
 
 
 
 
 
 
 
111
 
112
+ $npc_query = new WP_Query( $npc_args );
113
+ ?>
114
+ <ul id="npcatch" class="npcatch">
115
+ <?php
116
+ if( $npc_query->have_posts() ) :
117
+ while( $npc_query->have_posts() ) : $npc_query->the_post();
118
+ $post_date = ( isset( $instance['date']['active'] ) && $instance['date']['active'] == 1 ) ? '<span class="date">' . get_the_time( get_option('date_format') ) . '</span>' : '';
119
+
120
+ if( has_post_thumbnail() ) {
121
+ $thumb_id = get_post_thumbnail_id();
122
+ $thumb_url = wp_get_attachment_image_src($thumb_id);
123
+ $thumb_url = $thumb_url[0];
124
+ } else {
125
+ $thumb_url = $this->no_thumb_image();
126
+ }
127
+
128
+ $post_id = $npc_query->post->ID;
129
+ $post_title = apply_filters( 'npc_post_title', '<span class="title">' . wp_kses_post( get_the_title() ) . '</span>', $post_id );
130
+ $post_permalink = apply_filters( 'npc_post_permalink', get_permalink(), $post_id );
131
+ ?>
132
+ <li>
133
+ <a href="<?php echo esc_url( $post_permalink ); ?>" title="<?php echo esc_attr( $post_title ); ?>">
134
+ <figure>
135
+ <img src="<?php echo esc_url( $thumb_url ); ?>" width="<?php echo esc_attr( $width ); ?>" height="<?php echo esc_attr( $height ); ?>" alt="<?php echo esc_attr( $post_title ); ?>" title="<?php echo esc_attr( $post_title ); ?>"/>
136
+ </figure>
137
+ <div class="detail">
138
+ <?php echo $post_title; ?>
139
+ <?php echo $post_date; ?>
140
+ </div>
141
+ </a>
142
+ </li>
143
+ <?php
144
+ endwhile;
145
+ else :
146
+ ?>
147
+ <p>no post</p>
148
+ <?php endif; wp_reset_postdata(); ?>
149
+ </ul>
150
+
151
+ <?php
152
  echo $after_widget;
153
  }
154
 
184
 
185
  // define default value
186
  $defaults = array(
187
+ 'title' => __('LatestPost(s)' , 'newpost-catch'),
188
+ 'width' => 10,
189
+ 'height' => 10,
190
+ 'number' => 5,
191
+ 'date' => array( 'active' => false ),
192
+ 'ignore_check' => array( 'active' => false ),
193
+ 'css' => array( 'active' => true ),
194
+ 'cat' => NULL,
195
+ 'post_type' => 'post',
196
+ );
197
 
198
  $instance = wp_parse_args( (array) $instance, $defaults );
199
+ ?>
200
+ <p>
201
+ <label for="<?php echo $this->get_field_id('title'); ?>"><?php _e('Title' , 'newpost-catch'); ?></label>
202
+ <input id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" class="widefat" value="<?php echo esc_attr($instance['title']); ?>" />
203
+ </p>
204
+ <p>
205
+ <?php _e('Thumbnail Size' , 'newpost-catch'); ?><br />
206
+ <label for="<?php echo $this->get_field_id('width'); ?>"><?php _e('Width' , 'newpost-catch'); ?></label>
207
+ <input id="<?php echo $this->get_field_id('width'); ?>" name="<?php echo $this->get_field_name( 'width' ); ?>" type="text" style="width:50px" value="<?php echo esc_attr($instance['width']); ?>" /> px
208
+ <br />
209
+ <label for="<?php echo $this->get_field_id('height'); ?>"><?php _e('Height' , 'newpost-catch'); ?></label>
210
+ <input id="<?php echo $this->get_field_id('height'); ?>" name="<?php echo $this->get_field_name('height'); ?>" type="text" style="width:50px;" value="<?php echo esc_attr($instance['height']); ?>" /> px
211
+ </p>
212
+ <p>
213
+ <label for="<?php echo $this->get_field_id('number'); ?>"><?php _e('Show post(s)' , 'newpost-catch'); ?></label>
214
+ <input style="width:30px;" id="<?php echo $this->get_field_id('number'); ?>" name="<?php echo $this->get_field_name('number'); ?>" type="text" value="<?php echo esc_attr($instance['number']); ?>" /> <?php _e('Post(s)', 'newpost-catch'); ?>
215
+ </p>
216
+ <p>
217
+ <input type="checkbox" class="checkbox" value='1' <?php echo ($instance['date']['active']) ? 'checked="checked"' : ''; ?> id="<?php echo $this->get_field_id( 'date' ); ?>" name="<?php echo $this->get_field_name( 'date' ); ?>" /> <label for="<?php echo $this->get_field_id( 'date' ); ?>"><?php _e('Display date', 'newpost-catch'); ?></label>
218
+ </p>
219
+ <p>
220
+ <input type="checkbox" class="checkbox" value='1' <?php echo ($instance['ignore_check']['active']) ? 'checked="checked"' : ''; ?> id="<?php echo $this->get_field_id( 'ignore_check' ); ?>" name="<?php echo $this->get_field_name( 'ignore_check' ); ?>" /> <label for="<?php echo $this->get_field_id( 'ignore_check' ); ?>"><?php _e('Display sticky post', 'newpost-catch'); ?></label>
221
+ </p>
222
+ <p>
223
+ <input type="checkbox" class="checkbox" value='1' <?php if($instance['css']['active']){ echo 'checked="checked"'; } else { echo ''; } ?> id="<?php echo $this->get_field_id( 'css' ); ?>" name="<?php echo $this->get_field_name( 'css' ); ?>" /> <label for="<?php echo $this->get_field_id( 'css' ); ?>"><?php _e('Use default css', 'newpost-catch'); ?></label>
224
+ </p>
225
  <?php _e('Post types' , 'newpost-catch'); ?><br />
226
+ <?php
227
+ $args = array(
228
+ 'public' => true,
229
+ );
230
+
231
+ $output = 'objects';
232
+ $operator = 'and';
233
+
234
+ $post_types = get_post_types( $args, $output, $operator );
235
+ foreach ( $post_types as $post_type ) {
236
+ if( $post_type->name !== 'attachment' ){
237
+ ?>
238
+ <p><input type="radio" id="<?php echo $this->get_field_name($post_type->name); ?>" name="<?php echo $this->get_field_name('post_type'); ?>" value="<?php echo $post_type->name; ?>" <?php echo ( $instance['post_type'] == $post_type->name ) ? 'checked="checked"' : ''; ?> > <label for="<?php echo $this->get_field_name($post_type->name); ?>"><?php echo $post_type->labels->singular_name . '(' . $post_type->name . ')'; ?></label></p>
239
+ <?php
240
+ }
241
+ }
242
+ ?>
243
+ <?php if( $instance['post_type'] == 'post' ){ ?>
244
+ <p>
245
+ <label for="<?php echo $this->get_field_id('cat'); ?>"><?php _e('Display category(ies)' , 'newpost-catch'); ?></label>
246
+ <input id="<?php echo $this->get_field_id('cat'); ?>" name="<?php echo $this->get_field_name('cat'); ?>" type="text" class="widefat" value="<?php echo esc_attr($instance['cat']); ?>" />
247
+ <span><a href="<?php echo get_bloginfo('url') . '/wp-admin/edit-tags.php?taxonomy=category'; ?>"><?php _e('Check the category ID' , 'newpost-catch'); ?></a></span>
248
+ </p>
249
+ <?php } ?>
250
+ <p>
251
+ <?php _e('Use shortcode' , 'newpost-catch'); ?>
252
+ <?php _e('Can use the shortcode in a textwidget and theme files.' , 'newpost-catch'); ?> <a href="http://wordpress.org/plugins/newpost-catch/faq/" target="_blank">FAQ</a>
253
+ </p>
254
+ <p>
255
+ <?php _e('Support' , 'newpost-catch'); ?>
256
+ <a href="https://support.animagate.com/community/" target="_blank">User Community</a>
257
+ </p>
258
+ <?php
 
259
  }
260
  }
261
  }
322
  while( $npc_sc_query->have_posts() ) :
323
  $npc_sc_query->the_post();
324
 
325
+ $post_date = ( $date == true ) ? '<span class="date">' . esc_html( get_the_time( get_option('date_format') ) ) . '</span>' : '';
326
 
327
  $thumb_url = '';
328
  if( has_post_thumbnail( get_the_ID() ) ) {
333
  $thumb_url = $npc_construct->no_thumb_image();
334
  }
335
 
336
+ $post_id = $npc_sc_query->post->ID;
337
+ $post_title = apply_filters( 'npc_sc_post_title', '<span class="title">' . wp_kses_post( get_the_title() ) . '</span>', $post_id );
338
+ $post_permalink = apply_filters( 'npc_sc_post_permalink', get_permalink(), $post_id );
339
+
340
+ $html .= '<li><a href="' . esc_url( $post_permalink ) . '" title="' . esc_attr( $post_title ) . '">';
341
+ $html .= '<figure><img src="' . esc_url( $thumb_url ) . '" width="' . esc_attr( $width ) . '" height="' . esc_attr( $height ) . '" alt="' . esc_attr( $post_title ) . '" title="' . esc_attr( $post_title ) . '" /></figure>';
342
+ $html .= '<div class="detail">';
343
+ $html .= $post_title;
344
+ $html .= $post_date;
345
+ $html .= '</div></a></li>';
346
  endwhile;
347
  $html .= '</ul>';
348
  endif;
351
  return $html;
352
  }
353
  }
354
+ }
newpost-catch.php CHANGED
@@ -3,7 +3,7 @@
3
  Plugin Name: Newpost Catch
4
  Plugin URI: http://www.imamura.biz/blog/newpost-catch/
5
  Description: Thumbnails in new articles setting widget.
6
- Version: 1.3.5
7
  Author: Tetsuya Imamura
8
  Text Domain: newpost-catch
9
  Author URI: http://www.imamura.biz/blog/
@@ -33,4 +33,4 @@ new NewpostCatch_SC();
33
  You should have received a copy of the GNU General Public License
34
  along with this program; if not, write to the Free Software
35
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
36
- */
3
  Plugin Name: Newpost Catch
4
  Plugin URI: http://www.imamura.biz/blog/newpost-catch/
5
  Description: Thumbnails in new articles setting widget.
6
+ Version: 1.3.12
7
  Author: Tetsuya Imamura
8
  Text Domain: newpost-catch
9
  Author URI: http://www.imamura.biz/blog/
33
  You should have received a copy of the GNU General Public License
34
  along with this program; if not, write to the Free Software
35
  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
36
+ */
readme.txt CHANGED
@@ -2,9 +2,10 @@
2
  Contributors: s56bouya
3
  Donate link: http://www.imamura.biz/blog/newpost-catch
4
  Tags: widget, plugin, posts, sidebar, image, images, thumb, thumbnail
5
- Requires at least: 3.3.1
6
- Tested up to: 4.8.2
7
- Stable tag: 1.3.5
 
8
 
9
  Thumbnails in new articles setting widget.
10
 
@@ -21,7 +22,7 @@ Thumbnails in new articles setting widget.
21
  3. Activate the plugin through the 'Plugins' menu in WordPress
22
  4. Add the widget to your sidebar from Appearance->Widgets and configure the widget options.
23
 
24
- Required PHP5.3+
25
 
26
  ### Apply your own css style
27
 
@@ -88,135 +89,9 @@ When the post other than, post_type of the current page is the value of the prio
88
  == Screenshots ==
89
 
90
  1. To display the eye-catching(Thumbnail) set to Latest Post.
91
- 2. Localized support is in order.
92
  3. Is simple to add the side bar, to set the size of the thumbnail, posts, post date
93
 
94
  == Changelog ==
95
 
96
- = 1.3.5 =
97
- * Compatibility check with WP 4.8.2
98
- * Fixed : Get widget checkbox value
99
- * Change : Default CSS style
100
- * Change : Default image no_thumb.png
101
-
102
- = 1.3.4 =
103
- * Compatibility check with WP 4.7.3.
104
- * Change post_status only shows publish.
105
- * Meta_key parameter is available with shortcode.
106
-
107
- = 1.3.3 =
108
- * Compatibility check with WP 4.7.2.
109
- * Bugfix(thumbnail indication when shortcode was used).
110
-
111
- = 1.3.2 =
112
- * Compatibility check with WP 4.6.1.
113
-
114
- = 1.3.1 =
115
- * Required PHP5.3+(changed widgets_init hook).
116
- * Abolished option page.
117
- * Compatibility check with WP 4.5.
118
-
119
- = 1.3.0 =
120
- * Compatibility check with WP 4.4.2.
121
-
122
- = 1.2.9 =
123
- * Removed the same name method.
124
- * Apply filters default thumbnail.
125
-
126
- = 1.2.8 =
127
- * The constructor method was corrected.
128
-
129
- = 1.2.7 =
130
- * The css reading order adjustment.
131
-
132
- = 1.2.6 =
133
- * Compatibility check with WP 4.1 and Twenty Fifteen Theme.
134
-
135
- = 1.2.5 =
136
- * Use post types. Retrieves posts by Post Types.
137
-
138
- = 1.2.4 =
139
- * Compatibility check with WP 4.0.
140
-
141
- = 1.2.3 =
142
- * Compatibility check with WP 3.9.
143
-
144
- = 1.2.2 =
145
- * Bugfix(Link to the Setting Thumbnails in the widget).
146
-
147
- = 1.2.1 =
148
- * The translation file modification.
149
-
150
- = 1.2.0 =
151
- * Add Admin Menu「Setting Thumbnails」.
152
-
153
- = 1.1.9 =
154
- * Compatibility check with WP 3.8.1.
155
-
156
- = 1.1.8 =
157
- * Fixed reading of newpost-catch.css file (when using child themes)
158
-
159
- = 1.1.7 =
160
- * Compatibility check with WP 3.8.
161
-
162
- = 1.1.6 =
163
- * Compatibility check with WP 3.7.1.
164
- * Add Shortcode.
165
-
166
- = 1.1.5 =
167
- * Compatibility check with WP 3.6.
168
-
169
- = 1.1.4 =
170
- * Bugfix(the display the first image in the post).
171
-
172
- = 1.1.3 =
173
- * Bugfix.
174
-
175
- = 1.1.2 =
176
- * Compatibility check with WP 3.5.2.
177
- * Bugfix.
178
-
179
- = 1.1.1 =
180
-
181
- * Update Screenshots No.2.
182
-
183
- = 1.1.0 =
184
- * Compatibility check with WP 3.5.1.
185
- * Add option「Display date」「Display sticky post」「Use default css」「Display category(ies)」.
186
-
187
- = 1.0.9 =
188
- * Compatibility check with WP 3.5.
189
-
190
- = 1.0.8 =
191
- * Bugfix.
192
-
193
- = 1.0.7 =
194
- * Very minor changes that do not affect the operation of the plugin.
195
-
196
- = 1.0.6 =
197
- * Bugfix.
198
-
199
- = 1.0.5 =
200
- * Has been deleted in the action, webkit css3.
201
-
202
- = 1.0.4 =
203
- * If you do not have eye-catching image, the display the first image in the post.
204
- * In the setting of the widget, so that you can change the ratio of variable width and height of the image size.
205
-
206
- = 1.0.3 =
207
- * Update the [FAQ page](http://wordpress.org/extend/plugins/newpost-catch/faq/)
208
-
209
- = 1.0.2 =
210
- * [Dedicated plugin public page.](http://www.imamura.biz/blog/newpost-catch/)
211
- * Described in the [FAQ page](http://wordpress.org/extend/plugins/newpost-catch/faq/) "How to customize the css".
212
-
213
- = 1.0.1 =
214
- * Has been updated so that it does not include the "Stick this post to the front page".
215
- * A change since the previous version.
216
-
217
- = 1.0.0 =
218
- * First stable version.
219
-
220
- == Upgrade Notice ==
221
-
222
- Nothing in particular.
2
  Contributors: s56bouya
3
  Donate link: http://www.imamura.biz/blog/newpost-catch
4
  Tags: widget, plugin, posts, sidebar, image, images, thumb, thumbnail
5
+ Requires at least: 5.1
6
+ Requires PHP: 7.2
7
+ Tested up to: 5.8.3
8
+ Stable tag: 1.3.12
9
 
10
  Thumbnails in new articles setting widget.
11
 
22
  3. Activate the plugin through the 'Plugins' menu in WordPress
23
  4. Add the widget to your sidebar from Appearance->Widgets and configure the widget options.
24
 
25
+ Required PHP5.6+
26
 
27
  ### Apply your own css style
28
 
89
  == Screenshots ==
90
 
91
  1. To display the eye-catching(Thumbnail) set to Latest Post.
92
+ 2. Localized support is in order.
93
  3. Is simple to add the side bar, to set the size of the thumbnail, posts, post date
94
 
95
  == Changelog ==
96
 
97
+ See https://github.com/s56bouya/newpost-catch/commit/
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
style.css CHANGED
@@ -11,24 +11,23 @@ Please the name of the file to create and "newpost-catch.css". The other is the
11
 
12
  #npcatch li {
13
  margin: 0;
14
- overflow: hidden;
15
- clear: both;
16
- vertical-align: top;
17
  }
18
 
19
  #npcatch li a {
20
- display: table;
21
- padding: .5rem 0;
22
  width: 100%;
23
  }
24
 
25
- #npcatch img {
26
- float: left;
27
- padding: 0 .5rem 0 0;
 
 
 
28
  }
29
 
30
  #npcatch .title {
31
- overflow: hidden;
32
  display: block;
33
  }
34
 
11
 
12
  #npcatch li {
13
  margin: 0;
 
 
 
14
  }
15
 
16
  #npcatch li a {
17
+ display: flex;
18
+ padding: 0.5rem 0;
19
  width: 100%;
20
  }
21
 
22
+ #npcatch figure {
23
+ padding: 0 0.5rem 0 0;
24
+ }
25
+
26
+ #npcatch img{
27
+ height: auto;
28
  }
29
 
30
  #npcatch .title {
 
31
  display: block;
32
  }
33