Today I upgraded a client to 3.1 from 3.04. She's running multi-site. The functions.php file contains a section that is using get_ancestors and the entire site, including the dashboard gives me the double-bird now and won't load. I have no clue what to change to make it that function work again. When I comment out that portion, the dashboard reloads and the site does, too, except obviously with errors in the header call.
Do you have any bright ideas? :) I'm desperate to get her site back online and have had very, very little luck finding anything in Google or these forums. A few other things *kind of* like this, but with no resolutions.
This is the error I receive:
Fatal error: Cannot redeclare get_ancestors() (previously declared in /home/account_name/public_html/wp-includes/taxonomy.php:3055) in /home/account_name/public_html/wp-content/themes/account_name/functions.php on line 153
And this is the snippet it's referring to:
function get_ancestors ($p) {
$parent = $p->post_parent;
$ancestors = array ();
while ($parent != '0') {
if ($parent) {
$ancestors[] = $parent;
}
$p = get_post ($parent);
$parent = $p->post_parent;
}
return $ancestors;
}
I tried changing get_ancestors to get_post_ancestors, but it broke again and I wasn't sure what to do. I think something to do with wp-includes/post.php, but this is just a little beyond my scope.
I'd appreciate any insight. Thank you!