source/Application/Controller/ContentController.php
public function getContentId()
    {
        if ($this->_sContentId === null) {
            $sContentId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('oxcid');
            $sLoadId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('oxloadid');

            $this->_sContentId = false;
            $oContent = oxNew(\OxidEsales\Eshop\Application\Model\Content::class);

            if ($sLoadId) {
                $blRes = $oContent->loadByIdent($sLoadId);
            } elseif ($sContentId) {
                $blRes = $oContent->load($sContentId);
            } else {
                //get default content (impressum)
                $blRes = $oContent->loadByIdent('oximpressum');
            }

            if ($blRes && $oContent->oxcontents__oxactive->value) {
                $this->_sContentId = $oContent->oxcontents__oxid->value;
                $this->_oContent = $oContent;
            }
        }

        return $this->_sContentId;
    }
public function getContentId()
    {
        if ($this->_sContentId === null) {
            $sContentId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('oxcid');
            $sLoadId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('oxloadid');

            $this->_sContentId = false;
            $oContent = oxNew(\OxidEsales\Eshop\Application\Model\Content::class);

            if ($sLoadId) {
                $blRes = $oContent->loadByIdent($sLoadId);
            } elseif ($sContentId) {
                $blRes = $oContent->load($sContentId);
            } else {
                //get default content (impressum)
                $blRes = $oContent->loadByIdent('oximpressum');
            }

            if ($blRes && $oContent->oxcontents__oxactive->value) {
                $this->_sContentId = $oContent->oxcontents__oxid->value;
                $this->_oContent = $oContent;
            }
        }

        return $this->_sContentId;
    }
public function getContentId ( ) { if ( $ this -> _sContentId === null ) { $ sContentId = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'oxcid' ) ; $ sLoadId = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'oxloadid' ) ; $ this -> _sContentId = false ; $ oContent = oxNew ( \ OxidEsales \ Eshop \ Application \ Model \ Content :: class ) ; if ( $ sLoadId ) { $ blRes = $ oContent -> loadByIdent ( $ sLoadId ) ; } elseif ( $ sContentId ) { $ blRes = $ oContent -> load ( $ sContentId ) ; } else { //get default content (impressum) $ blRes = $ oContent -> loadByIdent ( 'oximpressum' ) ; } if ( $ blRes && $ oContent -> oxcontents__oxactive -> value ) { $ this -> _sContentId = $ oContent -> oxcontents__oxid -> value ; $ this -> _oContent = $ oContent ; } } return $ this -> _sContentId ; }
Template variable getter. Returns active content id.
If no content id specified, uses "impressum" content id

@return object
Template variable getter . Returns active content id . If no content id specified uses impressum content id