Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/integrate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
fail-fast: false
matrix:
php: ["5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0"]
wordpress: ["5.5", "5.6", "5.7"]
wordpress: ["5.9.5","6.0.3","6.1.1"]
allowed_failure: [false]
# https://make.wordpress.org/core/2020/11/23/wordpress-and-php-8-0/
exclude:
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## Changelog

### Version 1.4.2

- Fix: misc php errors

### Version 1.4.1

- Fix: Corrects sloppy shortcode fixes.
Expand Down
8 changes: 7 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
"phpunit/phpunit": "^4 || ^5 || ^6 || ^7",
"squizlabs/php_codesniffer": "^3.5",
"wp-coding-standards/wpcs": "^2.3.0",
"yoast/phpunit-polyfills": "^0.2.0"
"yoast/phpunit-polyfills": "^1.0.1"
},
"scripts": {
"cs": [
Expand All @@ -51,5 +51,11 @@
"@putenv WP_MULTISITE=1",
"@composer integration"
]
},
"config": {
"allow-plugins": {
"composer/installers": true,
"dealerdirect/phpcodesniffer-composer-installer": true
}
}
}
7 changes: 5 additions & 2 deletions form.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@
<select class="widefat" id="<?php echo esc_attr( $this->get_field_id('post_status' ) ); ?>" name="<?php echo esc_attr( $this->get_field_name('post_status' ) ); ?>">
<?php
echo "<option value='any'" . selected( 'any', $post_status, false ) . ">Any</option>";
if ( ! function_exists( 'get_available_post_statuses' ) ) {
require_once ABSPATH . '/wp-admin/includes/post.php';
}
$pss = get_available_post_statuses();
foreach ( $pss as $k => $v ) {
printf(
Expand Down Expand Up @@ -180,7 +183,7 @@
<?php
$taxonomy_names = get_taxonomies( array( 'public' => true ) );
printf(
esc_html('Available: %', 'mini-loops'),
esc_html('Available: %s', 'mini-loops'),
implode( ', ', array_map( 'esc_html', $taxonomy_names ) )
); ?>)</small>
</label>
Expand Down Expand Up @@ -219,4 +222,4 @@

</div>

<div style="clear:both;"></div>
<div style="clear:both;"></div>
2 changes: 1 addition & 1 deletion mini-loops.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
Plugin Name: Mini Loops
Plugin URI: http://trepmal.com/plugins/mini-loops/
Description: Query posts and display them where you want
Version: 1.4.1
Version: 1.4.2
Author: Kailey Lampert
Author URI: http://kaileylampert.com

Expand Down
8 changes: 7 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: recent, recent posts, most recent, category posts, thumbnail, loop, widget
Donate link: http://kaileylampert.com/donate/
Requires at least: 3.5
Tested up to: 5.7
Stable tag: 1.4.1
Stable tag: 1.4.2
License: GPLv2 or later

Get recent posts, posts from categories, and more. Display as widget or with shortcodes and template tags.
Expand Down Expand Up @@ -340,6 +340,9 @@ Send your mo/po files to me at trepmal (at) gmail.com

== Upgrade Notice ==

= 1.4.2 =
Fix: misc php errors

= 1.4.1 =
Fix: Corrects sloppy shortcode fixes and Mini-Mini-Loops widget default settings.

Expand Down Expand Up @@ -378,6 +381,9 @@ Real image croping for thumbnails and several other new features. See Changelog.

== Changelog ==

= Version 1.4.2 =
* Fix: misc php errors

= Version 1.4.1 =
* Fix: Corrects sloppy shortcode fixes.
* Fix: Mini-Mini-Loops widget default settings.
Expand Down
6 changes: 4 additions & 2 deletions widget.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ function widget( $args, $instance ) {
// phpcs:disable WordPress.Security.EscapeOutput.OutputNotEscaped

echo $args['before_widget'];
if ( ! $instance['hide_title'] ) {
$title = apply_filters( 'widget_title', $instance['title'] );
$hide_title = ( isset( $instance['hide_title'] ) && $instance['hide_title'] );
if ( ! $hide_title ) {
$title = apply_filters( 'widget_title', ( isset( $instance['title'] ) ? $instance['title'] : '' ) );
$title = empty( $instance['title_url'] ) ? wp_kses_post( $title ) : '<a href="'. esc_url( $instance['title_url'] ) .'">'. wp_kses_post( $title ) .'</a>';
echo $args['before_title'] . $title . $args['after_title'];
}
Expand Down Expand Up @@ -117,6 +118,7 @@ function form( $instance ) {
<input class="widefat" id="<?php echo esc_attr( $this->get_field_id('number_posts' ) ); ?>" name="<?php echo esc_attr( $this->get_field_name('number_posts') ); ?>" type="number" value="<?php echo esc_attr( $number_posts ); ?>" />
</label>
</p>
<br style="clear:both;">
<input name="<?php echo esc_attr( $this->get_field_name('post_offset') ); ?>" type="hidden" value="<?php echo esc_attr( $post_offset ); ?>" />
<input name="<?php echo esc_attr( $this->get_field_name('maximum_age') ); ?>" type="hidden" value="<?php echo esc_attr( $maximum_age ); ?>" />
<input name="<?php echo esc_attr( $this->get_field_name('post_type') ); ?>" type="hidden" value="<?php echo esc_attr( $post_type ); ?>" />
Expand Down