source/Core/Utils.php
public function canPreview()
    {
        $blCan = null;
        if (($sPrevId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('preview')) &&
            ($sAdminSid = \OxidEsales\Eshop\Core\Registry::getUtilsServer()->getOxCookie('admin_sid'))
        ) {
            $sTable = getViewName('oxuser');
            $oDb = \OxidEsales\Eshop\Core\DatabaseProvider::getDb();
            $sQ = "select 1 from $sTable where MD5( CONCAT( " . $oDb->quote($sAdminSid) . ", {$sTable}.oxid, {$sTable}.oxpassword, {$sTable}.oxrights ) ) = " . \OxidEsales\Eshop\Core\DatabaseProvider::getDb()->quote($sPrevId);
            $blCan = (bool) $oDb->getOne($sQ);
        }

        return $blCan;
    }
public function canPreview()
    {
        $blCan = null;
        if (($sPrevId = \OxidEsales\Eshop\Core\Registry::getConfig()->getRequestParameter('preview')) &&
            ($sAdminSid = \OxidEsales\Eshop\Core\Registry::getUtilsServer()->getOxCookie('admin_sid'))
        ) {
            $sTable = getViewName('oxuser');
            $oDb = \OxidEsales\Eshop\Core\DatabaseProvider::getDb();
            $sQ = "select 1 from $sTable where MD5( CONCAT( " . $oDb->quote($sAdminSid) . ", {$sTable}.oxid, {$sTable}.oxpassword, {$sTable}.oxrights ) ) = " . \OxidEsales\Eshop\Core\DatabaseProvider::getDb()->quote($sPrevId);
            $blCan = (bool) $oDb->getOne($sQ);
        }

        return $blCan;
    }
public function canPreview ( ) { $ blCan = null ; if ( ( $ sPrevId = \ OxidEsales \ Eshop \ Core \ Registry :: getConfig ( ) -> getRequestParameter ( 'preview' ) ) && ( $ sAdminSid = \ OxidEsales \ Eshop \ Core \ Registry :: getUtilsServer ( ) -> getOxCookie ( 'admin_sid' ) ) ) { $ sTable = getViewName ( 'oxuser' ) ; $ oDb = \ OxidEsales \ Eshop \ Core \ DatabaseProvider :: getDb ( ) ; $ sQ = "select 1 from $sTable where MD5( CONCAT( " . $ oDb -> quote ( $ sAdminSid ) . ", {$sTable}.oxid, {$sTable}.oxpassword, {$sTable}.oxrights ) ) = " . \ OxidEsales \ Eshop \ Core \ DatabaseProvider :: getDb ( ) -> quote ( $ sPrevId ) ; $ blCan = ( bool ) $ oDb -> getOne ( $ sQ ) ; } return $ blCan ; }
Checks if preview mode is ON

@return bool
Checks if preview mode is ON