Changeset 2549275
- Timestamp:
- 06/16/2021 09:55:50 PM (5 years ago)
- Location:
- mini-loops
- Files:
-
- 10 edited
- 1 copied
-
tags/1.4.1 (copied) (copied from mini-loops/trunk)
-
tags/1.4.1/CHANGELOG.md (modified) (1 diff)
-
tags/1.4.1/helpers.php (modified) (1 diff)
-
tags/1.4.1/mini-loops.php (modified) (1 diff)
-
tags/1.4.1/readme.txt (modified) (3 diffs)
-
tags/1.4.1/widget.php (modified) (4 diffs)
-
trunk/CHANGELOG.md (modified) (1 diff)
-
trunk/helpers.php (modified) (1 diff)
-
trunk/mini-loops.php (modified) (1 diff)
-
trunk/readme.txt (modified) (3 diffs)
-
trunk/widget.php (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
mini-loops/tags/1.4.1/CHANGELOG.md
r2546965 r2549275 1 1 ## Changelog 2 3 ### Version 1.4.1 4 5 - Fix: Corrects sloppy shortcode fixes. 6 - Fix: Mini-Mini-Loops widget default settings. 2 7 3 8 ### Version 1.4 -
mini-loops/tags/1.4.1/helpers.php
r2546965 r2549275 316 316 $atts['item_format'] = do_shortcode( $content ); 317 317 } elseif ( ! empty( $content) ) { 318 $content = ltrim( $content, '</p>' ); 319 $content = rtrim( $content, '<p>' ); 318 // for some annoying reason, shortcode content often ends up like this: 319 // `</p>%thecontent%<p>` 320 // so we explicitly look for these errant tags and remove them 321 if ( substr( $content, 0, 4 ) === '</p>' ){ 322 $content = substr( $content, 4 ); 323 } 324 if ( substr( $content, -3 ) === '<p>' ){ 325 $content = substr( $content, 0, -3 ); 326 } 320 327 $atts['item_format'] = miniloops_straighten_quote( $content ); 321 328 } -
mini-loops/tags/1.4.1/mini-loops.php
r2546965 r2549275 5 5 Plugin URI: http://trepmal.com/plugins/mini-loops/ 6 6 Description: Query posts and display them where you want 7 Version: 1.4 7 Version: 1.4.1 8 8 Author: Kailey Lampert 9 9 Author URI: http://kaileylampert.com -
mini-loops/tags/1.4.1/readme.txt
r2546965 r2549275 5 5 Requires at least: 3.5 6 6 Tested up to: 5.7 7 Stable tag: 1.4 7 Stable tag: 1.4.1 8 8 License: GPLv2 or later 9 9 … … 341 341 == Upgrade Notice == 342 342 343 = 1.4.1 = 344 Fix: Corrects sloppy shortcode fixes and Mini-Mini-Loops widget default settings. 345 343 346 = 1.4 = 344 347 General updates, improved shortcode compat with the Block Editor. … … 375 378 376 379 == Changelog == 380 381 = Version 1.4.1 = 382 * Fix: Corrects sloppy shortcode fixes. 383 * Fix: Mini-Mini-Loops widget default settings. 377 384 378 385 = Version 1.4 = -
mini-loops/tags/1.4.1/widget.php
r2546965 r2549275 39 39 //get old variables 40 40 $instance['title'] = wp_kses_post( $new_instance['title'] ); 41 $instance['hide_title'] = (bool) isset( $new_instance['hide_title'] ) ? 1 : 0;41 $instance['hide_title'] = (bool) isset( $new_instance['hide_title'] ) && $new_instance['hide_title'] ? 1 : 0; 42 42 $instance['title_url'] = esc_url( $new_instance['title_url'] ); 43 43 $instance['number_posts'] = (int) $new_instance['number_posts']; … … 49 49 $instance['order'] = esc_attr( $new_instance['order'] ); 50 50 $instance['order_meta_key'] = esc_attr( $new_instance['order_meta_key'] ); 51 $instance['reverse_order'] = (bool) isset( $new_instance['reverse_order'] ) ? 1 : 0;52 $instance['shuffle_order'] = (bool) isset( $new_instance['shuffle_order'] ) ? 1 : 0;53 $instance['ignore_sticky'] = (bool) isset( $new_instance['ignore_sticky'] ) ? 1 : 0;54 $instance['only_sticky'] = (bool) isset( $new_instance['only_sticky'] ) ? 1 : 0;55 $instance['exclude_sticky'] = (bool) isset( $new_instance['exclude_sticky'] ) ? 1 : 0;56 $instance['exclude_current'] = (bool) isset( $new_instance['exclude_current'] ) ? 1 : 0;57 $instance['current_category'] = (bool) isset( $new_instance['current_category'] ) ? 1 : 0;58 $instance['current_single_category'] = (bool) isset( $new_instance['current_single_category'] ) ? 1 : 0;59 $instance['current_author'] = (bool) isset( $new_instance['current_author'] ) ? 1 : 0;51 $instance['reverse_order'] = (bool) isset( $new_instance['reverse_order'] ) && $new_instance['reverse_order'] ? 1 : 0; 52 $instance['shuffle_order'] = (bool) isset( $new_instance['shuffle_order'] ) && $new_instance['shuffle_order'] ? 1 : 0; 53 $instance['ignore_sticky'] = (bool) isset( $new_instance['ignore_sticky'] ) && $new_instance['ignore_sticky'] ? 1 : 0; 54 $instance['only_sticky'] = (bool) isset( $new_instance['only_sticky'] ) && $new_instance['only_sticky'] ? 1 : 0; 55 $instance['exclude_sticky'] = (bool) isset( $new_instance['exclude_sticky'] ) && $new_instance['exclude_sticky'] ? 1 : 0; 56 $instance['exclude_current'] = (bool) isset( $new_instance['exclude_current'] ) && $new_instance['exclude_current'] ? 1 : 0; 57 $instance['current_category'] = (bool) isset( $new_instance['current_category'] ) && $new_instance['current_category'] ? 1 : 0; 58 $instance['current_single_category'] = (bool) isset( $new_instance['current_single_category'] ) && $new_instance['current_single_category'] ? 1 : 0; 59 $instance['current_author'] = (bool) isset( $new_instance['current_author'] ) && $new_instance['current_author'] ? 1 : 0; 60 60 $instance['categories'] = esc_attr( $new_instance['categories'] ); 61 61 $instance['tags'] = esc_attr( $new_instance['tags'] ); … … 97 97 $instance = wp_parse_args( (array) $instance, get_miniloops_defaults() ); 98 98 extract( $instance ); 99 100 99 ?> 101 100 <p><?php esc_html_e( 'Back to basics. Just recent posts. No fuss.', 'mini-loops' ); ?></p> … … 125 124 <input name="<?php echo esc_attr( $this->get_field_name('order_by') ); ?>" type="hidden" value="<?php echo esc_attr( $order_by ); ?>" /> 126 125 <input name="<?php echo esc_attr( $this->get_field_name('order') ); ?>" type="hidden" value="<?php echo esc_attr( $order ); ?>" /> 126 <input name="<?php echo esc_attr( $this->get_field_name('order_meta_key') ); ?>" type="hidden" value="<?php echo esc_attr( $order_meta_key ); ?>" /> 127 127 <input name="<?php echo esc_attr( $this->get_field_name('reverse_order') ); ?>" type="hidden" value="<?php echo esc_attr( $reverse_order ); ?>" /> 128 128 <input name="<?php echo esc_attr( $this->get_field_name('shuffle_order') ); ?>" type="hidden" value="<?php echo esc_attr( $shuffle_order ); ?>" /> -
mini-loops/trunk/CHANGELOG.md
r2546965 r2549275 1 1 ## Changelog 2 3 ### Version 1.4.1 4 5 - Fix: Corrects sloppy shortcode fixes. 6 - Fix: Mini-Mini-Loops widget default settings. 2 7 3 8 ### Version 1.4 -
mini-loops/trunk/helpers.php
r2546965 r2549275 316 316 $atts['item_format'] = do_shortcode( $content ); 317 317 } elseif ( ! empty( $content) ) { 318 $content = ltrim( $content, '</p>' ); 319 $content = rtrim( $content, '<p>' ); 318 // for some annoying reason, shortcode content often ends up like this: 319 // `</p>%thecontent%<p>` 320 // so we explicitly look for these errant tags and remove them 321 if ( substr( $content, 0, 4 ) === '</p>' ){ 322 $content = substr( $content, 4 ); 323 } 324 if ( substr( $content, -3 ) === '<p>' ){ 325 $content = substr( $content, 0, -3 ); 326 } 320 327 $atts['item_format'] = miniloops_straighten_quote( $content ); 321 328 } -
mini-loops/trunk/mini-loops.php
r2546965 r2549275 5 5 Plugin URI: http://trepmal.com/plugins/mini-loops/ 6 6 Description: Query posts and display them where you want 7 Version: 1.4 7 Version: 1.4.1 8 8 Author: Kailey Lampert 9 9 Author URI: http://kaileylampert.com -
mini-loops/trunk/readme.txt
r2546965 r2549275 5 5 Requires at least: 3.5 6 6 Tested up to: 5.7 7 Stable tag: 1.4 7 Stable tag: 1.4.1 8 8 License: GPLv2 or later 9 9 … … 341 341 == Upgrade Notice == 342 342 343 = 1.4.1 = 344 Fix: Corrects sloppy shortcode fixes and Mini-Mini-Loops widget default settings. 345 343 346 = 1.4 = 344 347 General updates, improved shortcode compat with the Block Editor. … … 375 378 376 379 == Changelog == 380 381 = Version 1.4.1 = 382 * Fix: Corrects sloppy shortcode fixes. 383 * Fix: Mini-Mini-Loops widget default settings. 377 384 378 385 = Version 1.4 = -
mini-loops/trunk/widget.php
r2546965 r2549275 39 39 //get old variables 40 40 $instance['title'] = wp_kses_post( $new_instance['title'] ); 41 $instance['hide_title'] = (bool) isset( $new_instance['hide_title'] ) ? 1 : 0;41 $instance['hide_title'] = (bool) isset( $new_instance['hide_title'] ) && $new_instance['hide_title'] ? 1 : 0; 42 42 $instance['title_url'] = esc_url( $new_instance['title_url'] ); 43 43 $instance['number_posts'] = (int) $new_instance['number_posts']; … … 49 49 $instance['order'] = esc_attr( $new_instance['order'] ); 50 50 $instance['order_meta_key'] = esc_attr( $new_instance['order_meta_key'] ); 51 $instance['reverse_order'] = (bool) isset( $new_instance['reverse_order'] ) ? 1 : 0;52 $instance['shuffle_order'] = (bool) isset( $new_instance['shuffle_order'] ) ? 1 : 0;53 $instance['ignore_sticky'] = (bool) isset( $new_instance['ignore_sticky'] ) ? 1 : 0;54 $instance['only_sticky'] = (bool) isset( $new_instance['only_sticky'] ) ? 1 : 0;55 $instance['exclude_sticky'] = (bool) isset( $new_instance['exclude_sticky'] ) ? 1 : 0;56 $instance['exclude_current'] = (bool) isset( $new_instance['exclude_current'] ) ? 1 : 0;57 $instance['current_category'] = (bool) isset( $new_instance['current_category'] ) ? 1 : 0;58 $instance['current_single_category'] = (bool) isset( $new_instance['current_single_category'] ) ? 1 : 0;59 $instance['current_author'] = (bool) isset( $new_instance['current_author'] ) ? 1 : 0;51 $instance['reverse_order'] = (bool) isset( $new_instance['reverse_order'] ) && $new_instance['reverse_order'] ? 1 : 0; 52 $instance['shuffle_order'] = (bool) isset( $new_instance['shuffle_order'] ) && $new_instance['shuffle_order'] ? 1 : 0; 53 $instance['ignore_sticky'] = (bool) isset( $new_instance['ignore_sticky'] ) && $new_instance['ignore_sticky'] ? 1 : 0; 54 $instance['only_sticky'] = (bool) isset( $new_instance['only_sticky'] ) && $new_instance['only_sticky'] ? 1 : 0; 55 $instance['exclude_sticky'] = (bool) isset( $new_instance['exclude_sticky'] ) && $new_instance['exclude_sticky'] ? 1 : 0; 56 $instance['exclude_current'] = (bool) isset( $new_instance['exclude_current'] ) && $new_instance['exclude_current'] ? 1 : 0; 57 $instance['current_category'] = (bool) isset( $new_instance['current_category'] ) && $new_instance['current_category'] ? 1 : 0; 58 $instance['current_single_category'] = (bool) isset( $new_instance['current_single_category'] ) && $new_instance['current_single_category'] ? 1 : 0; 59 $instance['current_author'] = (bool) isset( $new_instance['current_author'] ) && $new_instance['current_author'] ? 1 : 0; 60 60 $instance['categories'] = esc_attr( $new_instance['categories'] ); 61 61 $instance['tags'] = esc_attr( $new_instance['tags'] ); … … 97 97 $instance = wp_parse_args( (array) $instance, get_miniloops_defaults() ); 98 98 extract( $instance ); 99 100 99 ?> 101 100 <p><?php esc_html_e( 'Back to basics. Just recent posts. No fuss.', 'mini-loops' ); ?></p> … … 125 124 <input name="<?php echo esc_attr( $this->get_field_name('order_by') ); ?>" type="hidden" value="<?php echo esc_attr( $order_by ); ?>" /> 126 125 <input name="<?php echo esc_attr( $this->get_field_name('order') ); ?>" type="hidden" value="<?php echo esc_attr( $order ); ?>" /> 126 <input name="<?php echo esc_attr( $this->get_field_name('order_meta_key') ); ?>" type="hidden" value="<?php echo esc_attr( $order_meta_key ); ?>" /> 127 127 <input name="<?php echo esc_attr( $this->get_field_name('reverse_order') ); ?>" type="hidden" value="<?php echo esc_attr( $reverse_order ); ?>" /> 128 128 <input name="<?php echo esc_attr( $this->get_field_name('shuffle_order') ); ?>" type="hidden" value="<?php echo esc_attr( $shuffle_order ); ?>" />
Note: See TracChangeset
for help on using the changeset viewer.