public function parentPageId($noOverride = false)
    {
        if ($this->pageOverride && !$noOverride) {
            return $this->pageOverride->parent;
        } else {
            return ($parentIndex = (count($this->pageLevels) - 2)) >= 0 ? $this->pageLevels[$parentIndex]->id : 0;
        }
    }
public function parentPageId($noOverride = false)
    {
        if ($this->pageOverride && !$noOverride) {
            return $this->pageOverride->parent;
        } else {
            return ($parentIndex = (count($this->pageLevels) - 2)) >= 0 ? $this->pageLevels[$parentIndex]->id : 0;
        }
    }
public function parentPageId ( $ noOverride = false ) { if ( $ this -> pageOverride && ! $ noOverride ) { return $ this -> pageOverride -> parent ; } else { return ( $ parentIndex = ( count ( $ this -> pageLevels ) - 2 ) ) >= 0 ? $ this -> pageLevels [ $ parentIndex ] -> id : 0 ; } }
Get parent page id based on the page levels loaded from url
@param bool $noOverride
@return int
Get parent page id based on the page levels loaded from url