Jump to content

can't get some pages without include=all


kater
 Share

Recommended Posts

hi,

guess i screwed up again but i fail to find the problem.

maybe someone can point me to a direction? :)

- there are a couple of pages (out of thousands) which i can't get/find/count unless i use include=all.

- none of these are either hidden, unpublished, trashed, access managed, or anything that would obviously differ them from the other pages with the same template.

- finder in the backend can also only find those pages using include=all as custom selector.

If i get without include=all, i'll end up with a "Error: Call to a member function numChildren() on a non-object (line 976 of ... /wire/core/Pages.php)". Thought there is no need for include=all in get anyway?

$eactivity = $row[0];
    $numberexist = $pages->count("activityid={$eactivity}, include=all");
      if ($numberexist >= 1) {
        $p = $pages->get("activityid={$eactivity}, include=all");
          ....
Link to comment
Share on other sites

Seems it happens to pages in which i update a page field via API. Going to check that again.

-> Those older pages had fields as page arrays but at some point got a value? assigned. Don't know how that happend without throwing an error. However, solved.

Link to comment
Share on other sites

  • 9 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...