WordPress.org

Ready to get started?Download WordPress

Forums

[resolved] PHP Warning: post-template.php on line 1039 (6 posts)

  1. RockRealty
    Member
    Posted 1 year ago #

    I have been receiving the following error and now I can't access any links to blogs or pages on my WP site. http://blog.rockrealtywi.com

    [04-Jan-2013 15:21:51] PHP Warning: in_array() [function.in-array]: Wrong datatype for second argument in /home1/rockreic/public_html/blog/wp-includes/post-template.php on line 1039

  2. RockRealty
    Member
    Posted 1 year ago #

    I believe this is the line 1039 that it's talking about.

    if ( in_array( $page->ID, $_current_page->ancestors ) )

  3. Brett Shumaker
    Member
    Posted 1 year ago #

    The PHP warning means that $_current_page->ancestors does not have a datatype of 'array.'

    What changes had you recently made to the site right before it broke?

  4. RockRealty
    Member
    Posted 1 year ago #

    It looks like these errors started occurring back on Dec 27th and I had no idea. I don't believe any changes were made at that point.

    Today I re-installed WP 3.5 to see if that fixed it. I also attempted a different theme.

    Same issues still.

  5. RockRealty
    Member
    Posted 1 year ago #

    I resolved this by restoring a previous version of my .htaccess file in the WP root drive.

  6. Andrzej
    Member
    Posted 1 year ago #

    Is anyone else seeing the error_log entry? I have tried a simple .htaccess and the issue persists.

Topic Closed

This topic has been closed to new replies.

About this Topic