With PHP 7.2, this warning appears with the Intense Shortcodes plugin:
Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\_clients\flexo-academy\wp-content\plugins\intense\shortcodes\overlay\overlay-shortcode.php on line 44.
Updating the code as follows should correct this.
Current code (starting line 42):
if ( !empty( $image ) ) {
$alt = get_post_meta( $image, ‘_wp_attachment_image_alt’, true );
if (is_array($alt)==FALSE){
$alt=[];
}
}
Suggested Correction:
if ( !empty( $image ) ) {
$alt = get_post_meta( $image, ‘_wp_attachment_image_alt’, true );
if (is_array($alt)==FALSE){
$alt=[];
}
if ( count( $alt ) ) {
$atts[‘alt’] = $alt;
}
}
We love this plugin!