• I am getting the following error on a site I am attempting to launch. I have been building it on my localhost without issue. This is new since uploading the server:

    Warning: Invalid argument supplied for foreach() in ...\wp-includes\post.php on line 1468

    I went to those lines, which are:

    foreach ( $args->taxonomies as $taxonomy ) {
    	register_taxonomy_for_object_type( $taxonomy, $post_type );
    }

    I have commented them out, and the site seems to be loading OK. That, of course, is not a satisfactory solution.

    I do have several custom post types on this site.

Viewing 1 replies (of 1 total)
  • WordPress vesrion ?

    Have you tried:

    – deactivating all plugins to see if this resolves the problem. If this works, re-activate the plugins one by one until you find the problematic plugin(s).

    – switching to the default theme to rule out any theme-specific problems.

Viewing 1 replies (of 1 total)
  • The topic ‘Invalid argument supplied for foreach() …’ is closed to new replies.