public function getInheritedContensetZoneParams(ContentSet $contentSet)
    {
        $zone = null;

        if (
            null === $this->getLayout()
            || null === $this->getParent()
            || false === is_array($this->getLayout()->getZones())
        ) {
            return $zone;
        }

        $layoutZones = $this->getLayout()->getZones();
        $count = $this->getParent()->getContentSet()->count();
        for ($i = 0; $i < $count; $i++) {
            $parentContentset = $this->getParent()->getContentSet()->item($i);

            if ($contentSet->getUid() === $parentContentset->getUid()) {
                $zone = $layoutZones[$i];
            }
        }

        return $zone;
    }
public function getInheritedContensetZoneParams(ContentSet $contentSet)
    {
        $zone = null;

        if (
            null === $this->getLayout()
            || null === $this->getParent()
            || false === is_array($this->getLayout()->getZones())
        ) {
            return $zone;
        }

        $layoutZones = $this->getLayout()->getZones();
        $count = $this->getParent()->getContentSet()->count();
        for ($i = 0; $i < $count; $i++) {
            $parentContentset = $this->getParent()->getContentSet()->item($i);

            if ($contentSet->getUid() === $parentContentset->getUid()) {
                $zone = $layoutZones[$i];
            }
        }

        return $zone;
    }
public function getInheritedContensetZoneParams ( ContentSet $ contentSet ) { $ zone = null ; if ( null === $ this -> getLayout ( ) || null === $ this -> getParent ( ) || false === is_array ( $ this -> getLayout ( ) -> getZones ( ) ) ) { return $ zone ; } $ layoutZones = $ this -> getLayout ( ) -> getZones ( ) ; $ count = $ this -> getParent ( ) -> getContentSet ( ) -> count ( ) ; for ( $ i = 0 ; $ i < $ count ; $ i ++ ) { $ parentContentset = $ this -> getParent ( ) -> getContentSet ( ) -> item ( $ i ) ; if ( $ contentSet -> getUid ( ) === $ parentContentset -> getUid ( ) ) { $ zone = $ layoutZones [ $ i ] ; } } return $ zone ; }
Returns the inherited zone according to the provided ContentSet.

@param  ContentSet           $contentSet

@return \StdClass|null                           The inherited zone if found.
Returns the inherited zone according to the provided ContentSet .