• Resolved khairun

    (@khairun)


    After upgrading my word press website to 2.7 the following message appear & my website cannot be seen

    Warning: implode() [function.implode]: Invalid arguments passed in /home/khairun/public_html/dknphoto/wp-includes/query.php on line 1805

    Warning: Cannot modify header information – headers already sent by (output started at /home/khairun/public_html/dknphoto/wp-includes/query.php:1805) in /home/khairun/public_html/dknphoto/wp-includes/pluggable.php on line 850

    How to correct this?

    Khairun

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter khairun

    (@khairun)

    I have solved the problem.

    I simply copy & paste the file query.php from wp ver 2.65 into the file query.php wp ver 2.7

    Thank you.

    I had the same problem after upgrading to 2.7.1. The implode function expects an array (because it “joins” the array into a string), but for some reason the value being passed into it is numeric. It meant have something to do with the contentboxes plugin for me. Anyway, it’s easy to hack a fix for this in version 2.7’s query.php, which, though still not ideal, is better (IMO) than replacing the whole file with an earlier version.

    Replace this (line 1805):

    $cat_string = "'" . implode("', '", $q['category__not_in']) . "'";

    With this:

    $cat_not_in = is_numeric($q['category__not_in']) ? array($q['category__not_in']) : $q['category__not_in'];
    $cat_string = "'" . implode("', '", $cat_not_in) . "'";

    Hope that helps.

Viewing 3 replies - 1 through 3 (of 3 total)

The topic ‘Error message “function implode”’ is closed to new replies.