• Hi, I have upgraded to WordPress 4.4, but in a specific page of the website I get this warning.

    Warning: array_map(): Argument #2 should be an array in /home/jscm/webapps/XXXXX/wp-includes/category-template.php on line 1158

    How can I fix it?
    Can you help me?

    I use WordPress 4.4 with woothemes Canvas 5.9.10 (framework 6.2.2). The problem is visible in the specific “Magazine Page” of the Theme. Instead the warning reports a wordpress file.

Viewing 15 replies - 16 through 30 (of 54 total)
  • Thread Starter jscmal

    (@jscmal)

    I made a check, disabling the breadcrumb feature on Canvas Theme.

    I can confirm what Dough Smith told.

    Disabling the Breadcrumb, the Warning is not more visible.

    Thread Starter jscmal

    (@jscmal)

    It is related with the Breadcrumb but not for any page or post of the website.

    in the Canvas theme, it happens only for the Magazine Template Page.

    I haven’t quite figured out the exact cause yet, but the error is triggered by the wf_set_default_breadcrumb_taxonomies() function in the /functions/admin-functions.php file included in many Woo Themes themes.

    Hi Doug Smith, you are right. With Breadcrumbs enabled, the error appears on every Page except the Articles. I use the Canvas Theme from Woo. If I disable the Breadcrumbs, everything works fine!

    Heads up!! This may be the problem.

    If you’re seeing the error, check to see if you have Jetpack enabled. If you do, try disabling the Widget Visibility module to see if that removes the error from displaying on your site.

    This worked for me, but not sure if it’ll work for everyone. Of course, now all widgets are displayed

    Thread Starter jscmal

    (@jscmal)

    In my opinion disable Jetpack and his services is not a good thing. If I have to choice, I prefer to disable the breadcrumb that is not really relevant (in general).

    I need JetPack! …

    @jscmal – I agree with you; I need JetPack.

    The problem here for me is I’m not using a WooThemes theme and I don’t have breadcrumbs on this site in question ??

    Someone help please. 99% of our WordPress sites are either white or REALLY slow after this update.

    Even the ones with no plugins.

    Moderator Ipstenu (Mika Epstein)

    (@ipstenu)

    ?????? Advisor and Activist

    The art of debugging involves turning things off.

    Think of it like when you go to the doctor and you tell them your ankle hurts. They twist and turn and ask “Does it hurt when I do this? Or this?”

    You have to be willing to bend your ankle a little.

    Try disabling Widget Visibility. See if it works. Report back. We may have multiple issues going on.

    Moderator Samuel Wood (Otto)

    (@otto42)

    www.ads-software.com Admin

    First, if you ever see warnings publicly visible on your site, then you need to do the following:

    1. Ask your hosting service how to properly disable “display_errors”.

    2. Follow their instructions.

    The PHP display_errors setting should *never* be enabled on a live production site. This is a debugging tool only. Even if some hosts default to leaving it on, you should turn it off, always.

    The way that you do this is different on every host. On some hosts, you would make a PHP.INI file in your webroot and put this line into it:

    display_errors=Off

    On other hosts, you could add this line to your .htaccess file:

    php_flag display_errors off

    Sometimes you can add this to your wp-config.php file (near the top, where the define’s are):

    @ini_set('display_errors','Off');

    But ask your host for the proper way. They likely have some documentation in their help pages telling you how to do this.

    GoDaddy supports the PHP.INI file method, with various filenames:
    https://www.godaddy.com/help/changing-cpanel-shared-hosting-accounts-php-error-handling-8886
    https://www.godaddy.com/help/what-filename-does-my-php-initialization-file-need-to-use-8913

    Dreamhost uses a “phprc” file for configuring their hosting accounts:
    https://wiki.dreamhost.com/PHP.ini

    I have seen reports today of plugins also causing this error, so yes, do try disabling plugins systematically to see if that is the problem for you.

    I’ve tested with all plugins off and can confirm the error does occur with nothing but some of the Woo Themes themes. I’ve checked Canvas and Appply.

    @samuel nice advice for “hiding” the issue from the visitors…but how will admin know that the problem still exists if the errors are being hidden?

    Ahh, i understand now… it creates an error log for admin to view.

    The function I mentioned before is not the cause but is just triggering where it actually is happening.

    The following lines are in both the Canvas and Appply themes in /functions/admin-functions.php. This is where the error is triggered.

    if ( isset( $args["singular_{$post_type}_taxonomy"] ) ) {
    	$raw_terms = get_the_terms( $post_id, $args["singular_{$post_type}_taxonomy"] );

    On a page where I’m seeing the error, the value of $args is:

    Array ( [singular_page_taxonomy] => page )

    I have already posted to Woothemes to find a solution. We will see what happens in the next hours. Until then, I disable the Breadcrumb functionality in the Canvas Theme.

Viewing 15 replies - 16 through 30 (of 54 total)
  • The topic ‘Warning after the upgrade to WP 4.4’ is closed to new replies.