PluginProbe
Super RSS Reader – Add attractive RSS Feed Widget / 4.7
Super RSS Reader – Add attractive RSS Feed Widget v4.7
trunk 0.8 2.0 2.1 2.2 2.3 2.4 2.5 2.6 2.7 2.8 3.0 3.1 3.2 4.0 4.0.1 4.1 4.2 4.3 4.4 4.4.1 4.5 4.6 4.7 4.8 All 33 releases
← All changes | includes/widget-admin.php +1 -67 trunk4.7 View file →
@@ -49,9 +49,8 @@
49 49 $instance[ 'urls' ] = sanitize_textarea_field( $new_instance['urls'] ) ;
50 50 $instance[ 'tab_titles' ] = wp_kses_post( $new_instance['tab_titles'] );
51 51
52 52 $instance[ 'count' ] = intval( $new_instance['count'] );
53 - $instance[ 'show_title' ] = intval( isset( $new_instance['show_title'] ) ? $new_instance['show_title'] : 0 );
54 53 $instance[ 'show_date' ] = intval( isset( $new_instance['show_date'] ) ? $new_instance['show_date'] : 0 );
55 54 $instance[ 'show_desc' ] = intval( isset( $new_instance['show_desc'] ) ? $new_instance['show_desc'] : 0 );
56 55 $instance[ 'show_author' ] = intval( isset( $new_instance['show_author'] ) ? $new_instance['show_author'] : 0 );
57 56 $instance[ 'show_thumb' ] = intval( isset( $new_instance['show_thumb'] ) ? $new_instance['show_thumb'] : 0 );
@@ -56,9 +55,8 @@
56 55 $instance[ 'show_author' ] = intval( isset( $new_instance['show_author'] ) ? $new_instance['show_author'] : 0 );
57 56 $instance[ 'show_thumb' ] = intval( isset( $new_instance['show_thumb'] ) ? $new_instance['show_thumb'] : 0 );
58 57 $instance[ 'strip_desc' ] = intval( $new_instance['strip_desc'] );
59 58 $instance[ 'strip_title' ] = intval( $new_instance['strip_title'] );
60 - $instance[ 'offset' ] = intval( $new_instance['offset'] );
61 59 $instance[ 'date_format' ] = sanitize_text_field( $new_instance['date_format'] );
62 60 $instance[ 'date_timezone' ] = sanitize_text_field( $new_instance['date_timezone'] );
63 61 $instance[ 'order_by' ] = sanitize_text_field( $new_instance['order_by'] );
64 62 $instance[ 'read_more' ] = sanitize_text_field( $new_instance['read_more'] );
@@ -64,15 +62,12 @@
64 62 $instance[ 'read_more' ] = sanitize_text_field( $new_instance['read_more'] );
65 63 $instance[ 'add_nofollow' ] = intval( isset( $new_instance['add_nofollow'] ) ? $new_instance['add_nofollow'] : 0 );
66 64 $instance[ 'open_newtab' ] = intval( isset( $new_instance['open_newtab'] ) ? $new_instance['open_newtab'] : 0 );
67 65 $instance[ 'rich_desc' ] = intval( isset( $new_instance['rich_desc'] ) ? $new_instance['rich_desc'] : 0 );
68 - $instance[ 'link_desc' ] = intval( isset( $new_instance['link_desc'] ) ? $new_instance['link_desc'] : 0 );
69 66 $instance[ 'desc_type' ] = sanitize_text_field( $new_instance['desc_type'] );
70 67 $instance[ 'thumbnail_position' ] = sanitize_text_field( $new_instance['thumbnail_position'] );
71 - $instance[ 'thumbnail_crop_position' ] = sanitize_text_field( $new_instance['thumbnail_crop_position'] );
72 68 $instance[ 'thumbnail_size' ] = sanitize_text_field( $new_instance['thumbnail_size'] );
73 69 $instance[ 'thumbnail_default' ] = sanitize_text_field( $new_instance['thumbnail_default'] );
74 - $instance[ 'thumbnail_type' ] = sanitize_text_field( $new_instance['thumbnail_type'] );
75 70 $instance[ 'no_feed_text' ] = wp_kses_post( $new_instance['no_feed_text'] );
76 71
77 72 $instance[ 'color_style' ] = sanitize_text_field( $new_instance['color_style']);
78 73 $instance[ 'display_type' ] = sanitize_text_field( $new_instance['display_type']);
@@ -77,9 +72,8 @@
77 72 $instance[ 'color_style' ] = sanitize_text_field( $new_instance['color_style']);
78 73 $instance[ 'display_type' ] = sanitize_text_field( $new_instance['display_type']);
79 74 $instance[ 'visible_items' ] = intval( $new_instance['visible_items'] );
80 75 $instance[ 'ticker_speed' ] = intval( $new_instance['ticker_speed'] );
81 - $instance[ 'scroll_height' ] = sanitize_text_field( $new_instance['scroll_height'] );
82 76
83 77 return $instance;
84 78 }
85 79
@@ -92,9 +86,8 @@
92 86 $urls = $instance['urls'];
93 87 $tab_titles = $instance['tab_titles'];
94 88
95 89 $count = $instance['count'];
96 - $show_title = $instance['show_title'];
97 90 $show_date = $instance['show_date'];
98 91 $show_desc = $instance['show_desc'];
99 92 $show_author = $instance['show_author'];
100 93 $show_thumb = $instance['show_thumb'];
@@ -101,9 +94,8 @@
101 94 $open_newtab = $instance['open_newtab'];
102 95 $add_nofollow = $instance['add_nofollow'];
103 96 $strip_desc = $instance['strip_desc'];
104 97 $strip_title = $instance['strip_title'];
105 - $offset = $instance['offset'];
106 98 $date_format = $instance['date_format'];
107 99 $date_timezone = $instance['date_timezone'];
108 100 $order_by = $instance['order_by'];
109 101 $read_more = $instance['read_more'];
@@ -108,14 +100,11 @@
108 100 $order_by = $instance['order_by'];
109 101 $read_more = $instance['read_more'];
110 102 $rich_desc = $instance['rich_desc'];
111 103 $desc_type = $instance['desc_type'];
112 - $link_desc = $instance['link_desc'];
113 104 $thumbnail_position = $instance['thumbnail_position'];
114 - $thumbnail_crop_position = $instance['thumbnail_crop_position'];
115 105 $thumbnail_size = $instance['thumbnail_size'];
116 106 $thumbnail_default = $instance['thumbnail_default'];
117 - $thumbnail_type = $instance['thumbnail_type'];
118 107 $no_feed_text = $instance['no_feed_text'];
119 108
120 109 $color_style = $instance['color_style'];
121 110 $display_type = $instance['display_type'];
@@ -120,9 +109,8 @@
120 109 $color_style = $instance['color_style'];
121 110 $display_type = $instance['display_type'];
122 111 $visible_items = $instance['visible_items'];
123 112 $ticker_speed = $instance['ticker_speed'];
124 - $scroll_height = $instance['scroll_height'];
125 113
126 114 $option_lists = SRR_Options::select_options();
127 115
128 116 // Replacing commas with new lines
@@ -164,13 +152,8 @@
164 152 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('count') ); ?>" name="<?php echo esc_attr( $this->get_field_name('count') ); ?>" type="number" value="<?php echo esc_attr( $count ); ?>" class="widefat" /></div>
165 153 </div>
166 154
167 155 <div class="srr_row">
168 - <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('show_title') ); ?>"><?php esc_html_e( 'Show title', 'super-rss-reader' ); ?></label></div>
169 - <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('show_title') ); ?>" type="checkbox" name="<?php echo esc_attr( $this->get_field_name('show_title') ); ?>" value="1" <?php echo $show_title == "1" ? 'checked="checked"' : ""; ?> /></div>
170 - </div>
171 -
172 - <div class="srr_row">
173 156 <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('show_desc') ); ?>"><?php esc_html_e( 'Show Description', 'super-rss-reader' ); ?></label></div>
174 157 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('show_desc') ); ?>" type="checkbox" name="<?php echo esc_attr( $this->get_field_name('show_desc') ); ?>" value="1" <?php echo $show_desc == "1" ? 'checked="checked"' : ""; ?> /></div>
175 158 </div>
176 159
@@ -207,13 +190,8 @@
207 190 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('strip_title') ); ?>" name="<?php echo esc_attr( $this->get_field_name('strip_title') ); ?>" type="number" value="<?php echo esc_attr( $strip_title ); ?>" class="widefat" /></div>
208 191 </div>
209 192
210 193 <div class="srr_row">
211 - <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('offset') ); ?>"><?php esc_html_e( 'Offset', 'super-rss-reader' ); ?></label><?php $this->tt( __( 'The number of RSS feed items to skip from the top', 'super-rss-reader' ) ); ?></div>
212 - <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('offset') ); ?>" name="<?php echo esc_attr( $this->get_field_name('offset') ); ?>" type="number" value="<?php echo esc_attr( $offset ); ?>" class="widefat" /></div>
213 - </div>
214 -
215 - <div class="srr_row">
216 194 <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('order_by') ); ?>"><?php esc_html_e( 'Order feed items by', 'super-rss-reader' ); ?></label></div>
217 195 <div class="srr_field">
218 196 <?php
219 197 echo '<select name="' . $this->get_field_name('order_by') . '" id="' . $this->get_field_id('order_by') . '">';
@@ -257,13 +235,8 @@
257 235 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('read_more') ); ?>" name="<?php echo esc_attr( $this->get_field_name('read_more') ); ?>" type="text" value="<?php echo esc_attr( $read_more ); ?>" class="widefat" /></div>
258 236 </div>
259 237
260 238 <div class="srr_row">
261 - <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('link_desc') ); ?>"><?php esc_html_e( 'Link description text', 'super-rss-reader' ); ?></label><?php $this->tt( __( 'Wrap the description text with the link of the RSS feed item. Works only when rich description is disabled.', 'super-rss-reader' ) ); ?></div>
262 - <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('link_desc') ); ?>" type="checkbox" name="<?php echo esc_attr( $this->get_field_name('link_desc') ); ?>" value="1" <?php echo $link_desc == "1" ? 'checked="checked"' : ""; ?> /></div>
263 - </div>
264 -
265 - <div class="srr_row">
266 239 <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('rich_desc') ); ?>"><?php esc_html_e( 'Enable rich description', 'super-rss-reader' ); ?></label></div>
267 240 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('rich_desc') ); ?>" type="checkbox" name="<?php echo esc_attr( $this->get_field_name('rich_desc') ); ?>" value="1" <?php echo $rich_desc == "1" ? 'checked="checked"' : ""; ?> /></div>
268 241 </div>
269 242
@@ -286,21 +259,8 @@
286 259 </div>
287 260 </div>
288 261
289 262 <div class="srr_row">
290 - <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('thumbnail_crop_position') ); ?>"><?php esc_html_e( 'Thumbnail crop position', 'super-rss-reader' ); ?></label></div>
291 - <div class="srr_field">
292 - <?php
293 - echo '<select name="' . esc_attr( $this->get_field_name('thumbnail_crop_position') ) . '" id="' . esc_attr( $this->get_field_id('thumbnail_crop_position') ) . '">';
294 - foreach( $option_lists[ 'thumbnail_crop_position' ] as $k => $v ){
295 - echo '<option value="' . esc_attr( $k ) . '" ' . selected( $thumbnail_crop_position, $k, false ) . '>' . esc_html( $v ) . '</option>';
296 - }
297 - echo '</select>';
298 - ?>
299 - </div>
300 - </div>
301 -
302 - <div class="srr_row">
303 263 <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('thumbnail_size') ); ?>"><?php esc_html_e( 'Thumbnail size', 'super-rss-reader' ); ?></label><?php $this->tt( __( 'The size of the thumbnail including the units. Example 64px, 10%', 'super-rss-reader' ) ); ?></div>
304 264 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('thumbnail_size') ); ?>" name="<?php echo esc_attr( $this->get_field_name('thumbnail_size') ); ?>" type="text" value="<?php echo esc_attr( $thumbnail_size ); ?>" class="widefat" /></div>
305 265 </div>
306 266
@@ -316,21 +276,8 @@
316 276 </div>
317 277 </div>
318 278
319 279 <div class="srr_row">
320 - <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('thumbnail_type') ); ?>"><?php esc_html_e( 'The size of image to pick', 'super-rss-reader' ); ?></label><?php $this->tt( __( 'If the feed contains both thumbnail and full-size images, choose which image size to use.', 'super-rss-reader' ) ); ?></div>
321 - <div class="srr_field">
322 - <?php
323 - echo '<select name="' . esc_attr( $this->get_field_name('thumbnail_type') ) . '" id="' . esc_attr( $this->get_field_id('thumbnail_type') ) . '">';
324 - foreach( $option_lists[ 'thumbnail_type' ] as $k => $v ){
325 - echo '<option value="' . esc_attr( $k ) . '" ' . selected( $thumbnail_type, $k, false ) . '>' . esc_html( $v ) . '</option>';
326 - }
327 - echo '</select>';
328 - ?>
329 - </div>
330 - </div>
331 -
332 - <div class="srr_row">
333 280 <div class="srr_label"><label for="<?php echo esc_attr( $this->get_field_id('thumbnail_default') ); ?>"><?php esc_html_e( 'Default thumbnail image', 'super-rss-reader' ); ?></label><?php $this->tt( __( 'The URL of the default thumbnail image if not present. Leave empty to skip thumbnail if not present.', 'super-rss-reader' ) ); ?></div>
334 281 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('thumbnail_default') ); ?>" name="<?php echo esc_attr( $this->get_field_name('thumbnail_default') ); ?>" type="text" value="<?php echo esc_attr( $thumbnail_default ); ?>" class="widefat" /></div>
335 282 </div>
336 283
@@ -377,10 +324,8 @@
377 324 ?>
378 325 </div>
379 326 </div>
380 327
381 - <h4><?php esc_html_e( 'Ticker type settings', 'super-rss-reader' ); ?></h4>
382 -
383 328 <div class="srr_row">
384 329 <div class="srr_label srr_sm"><label for="<?php echo esc_attr( $this->get_field_id('ticker_speed') ); ?>"><?php esc_html_e( 'Ticker speed', 'super-rss-reader' ); ?></label></div>
385 330 <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('ticker_speed') ); ?>" name="<?php echo esc_attr( $this->get_field_name('ticker_speed') ); ?>" type="number" value="<?php echo esc_attr( $ticker_speed ); ?>" title="Speed of the ticker in seconds"/> seconds</div>
386 331 </div>
@@ -391,17 +336,8 @@
391 336 <small class="srr_small_text"><?php esc_html_e( 'Set value less than 20 to show visible feed items. Example: 5 items', 'super-rss-reader' ); ?></small></br>
392 337 <small class="srr_small_text"><?php esc_html_e( 'Set value greater than 20 for fixed widget height. Example: 400 px', 'super-rss-reader' ); ?></small></div>
393 338 </div>
394 339
395 - <h4><?php esc_html_e( 'Scroll type settings', 'super-rss-reader' ); ?></h4>
396 -
397 - <div class="srr_row">
398 - <div class="srr_label srr_sm"><label for="<?php echo esc_attr( $this->get_field_id('scroll_height') ); ?>"><?php esc_html_e( 'Maximum height of the widget', 'super-rss-reader' ); ?></label></div>
399 - <div class="srr_field"><input id="<?php echo esc_attr( $this->get_field_id('scroll_height') ); ?>" name="<?php echo esc_attr( $this->get_field_name('scroll_height') ); ?>" type="text" value="<?php echo esc_attr( $scroll_height ); ?>" title="Maximum height of the widget"/><br/>
400 - <small class="srr_small_text"><?php esc_html_e( 'Example: 400px', 'super-rss-reader' ); ?></small>
401 - </div>
402 - </div>
403 -
404 340 </section>
405 341
406 342 <section data-tab-id="filter" class="srr_pro_sec">
407 343
@@ -433,17 +369,15 @@
433 369
434 370 <div class="srr_pro">
435 371 <div class="srr_pro_intro">
436 372 <div><span class="srr_pro_label">PRO</span></div>
437 - <p>Get the PRO version to enjoy more features like<br/> <span>Shortcode, Grid display, Filter by keyword, Pagination</span> and more !</p>
373 + <p>Get the PRO version to enjoy more features like<br/> <span>Shortcode, Grid display, Filter by keyword</span> and more !</p>
438 374 <div><span class="dashicons dashicons-arrow-down-alt2 srr_pro_more"></span></div>
439 375 </div>
440 376 <div class="srr_pro_details">
441 377 <ul class="srr_pro_features">
442 - <li>Merge feeds - <span>Merge multiple feeds into one</span></li>
443 378 <li>Shortcode - <span>Display RSS feed anywhere in your website</span></li>
444 379 <li>Grid display - <span>Display feed item in rows and columns</span></li>
445 - <li>Paginated display - <span>Display feed item in different pages.</span></li>
446 380 <li>Filter by keyword - <span>Show/hide feed items based on keyword</span></li>
447 381 <li>Custom template - <span>Change order of feed item content, add HTML</span></li>
448 382 <li>Fetch thumbnail - <span>Forcefully fetches the thumbnail from feed URL.</span></li>
449 383 <li>4+ new color themes</li>