Warning within media.php

Dear Support,

While using X version 5.2.5 from November 15, 2017 in combination with WordPress version wordpress-4.9.1-de_DE I receive the following warning as soon as I select masonry layout option:

Warning: count(): Parameter must be an array or an object that implements Countable in C:\xampp\htdocs\x\wp-includes\media.php on line 1206

This issue is new (starting from the latest version) and appears on the is_home site directly above each article image.

Is this a known bug?
Is there anything I can do?

Thanks in advance!

BR

Hey There,

Thanks for writing in! You are seeing a PHP warning message. It may have came from an uninitialize variable in one of the grid items. You can get rid of this message by turning off the debug mode. You can do this by opening wp-config.php and adding:

define('WP_DEBUG', false);

When you revisit the page, you should no longer be seeing the message.

Please let us know how it goes.

Hi,

Unfortunately, that didn’t help.
That code was already included within the wp-config.php at the end of the file.
Additionally, I noticed that the Customizer doesn’t make any changes if I try to change max-site-width to 1500px instead of 1200px. So I can use the slide panel to change to 1500px in the front-end, but even the bottom to confirm that change, stays inactive. So I can’t change the value to 1500px in the end!

This is a fresh install without any adaptations.

Hi there,

It shouldn’t be added at the end of the file, you just need to edit the existing line and change it to false. I see a similar issue but due to migration, but you said it’s fresh installed. But unfortunately, there is no way to check it on your site. Maybe you could set up a temporary clone of your site accessible through the internet?

Thanks

Hi Rad,

These are my line of code (103-115) of wp-config.php:

/* Das war’s, Schluss mit dem Bearbeiten! Viel Spaß beim Bloggen. /
/
That’s all, stop editing! Happy blogging. */

/** Der absolute Pfad zum WordPress-Verzeichnis. */
if ( !defined(‘ABSPATH’) )
define(‘ABSPATH’, dirname(FILE) . ‘/’);

/** Definiert WordPress-Variablen und fügt Dateien ein. */
require_once(ABSPATH . ‘wp-settings.php’);

This line was already set to false!

Hope that helps!

I have used the following links (could you maybe try?):

  1. https://themeco-packages.s3.amazonaws.com/d940c8c440f230138995a40c4daf0904/x_package/x.zip
  2. https://de.wordpress.org/wordpress-4.9.1-de_DE.zip
    Issue was appearing as soon as you upload and display an image to an article -> the default article too

The customizer issue is a 2nd issue, but I can fix this via CSS !important.

The warning is the more important issue.

Please follow this article to disable warning messages.

If that does not help, can you try using the standard WordPress version https://wordpress.org/latest.zip.

We really need that you setup a dev site online. Otherwise, we cannot help because we could not check your WordPress admin and server. Once you’ve put your site online, please give us WP Admin and FTP access in a Secure Note.

Thanks.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.