Have to agree with @gillesvauvarin though, the docs should not call the argument the path but the uid (?) instead. I was just confused about the same thing, because the docs call it path, when clearly this does not take a full path.
@texnixe this just took me +1h haha. because the docs are not clear here. can confirm it’s only working with direct children. i guess it would be good if they were updated?
Some years later and I just wasted quite some time with the latest Kirby release (5.0.4) until I stumbled upon this thread – every attempt to pass a path to $site->findPageOrDraft didn’t work for me…
Yes, I agree, the behavior seems to be inconsistent somehow. If you pass a path to a published page, it works as expected, but not if the page is a draft.
Wondering if this is intended or a bug. It works if you pass a slug to a draft, but not a path.