src/ShopBundle/objects/db/TShop.class.php
public static function GetRegisteredActiveVariantForCurrentSpot($sParentId)
    {
        $sShopVariantArticleId = false;
        if (array_key_exists(TdbShop::SESSION_ACTIVE_VARIANT_ARRAY, $_SESSION)) {
            $oGlobal = TGlobal::instance();
            $oExecutingModuleSpot = $oGlobal->GetExecutingModulePointer();
            if ($oExecutingModuleSpot) {
                $sSpotName = $oExecutingModuleSpot->sModuleSpotName;
                if (array_key_exists($sSpotName, $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY]) && array_key_exists($sParentId, $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY][$sSpotName])) {
                    $sShopVariantArticleId = $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY][$sSpotName][$sParentId];
                }
            }
        }

        return $sShopVariantArticleId;
    }
public static function GetRegisteredActiveVariantForCurrentSpot($sParentId)
    {
        $sShopVariantArticleId = false;
        if (array_key_exists(TdbShop::SESSION_ACTIVE_VARIANT_ARRAY, $_SESSION)) {
            $oGlobal = TGlobal::instance();
            $oExecutingModuleSpot = $oGlobal->GetExecutingModulePointer();
            if ($oExecutingModuleSpot) {
                $sSpotName = $oExecutingModuleSpot->sModuleSpotName;
                if (array_key_exists($sSpotName, $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY]) && array_key_exists($sParentId, $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY][$sSpotName])) {
                    $sShopVariantArticleId = $_SESSION[TdbShop::SESSION_ACTIVE_VARIANT_ARRAY][$sSpotName][$sParentId];
                }
            }
        }

        return $sShopVariantArticleId;
    }
public static function GetRegisteredActiveVariantForCurrentSpot ( $ sParentId ) { $ sShopVariantArticleId = false ; if ( array_key_exists ( TdbShop :: SESSION_ACTIVE_VARIANT_ARRAY , $ _SESSION ) ) { $ oGlobal = TGlobal :: instance ( ) ; $ oExecutingModuleSpot = $ oGlobal -> GetExecutingModulePointer ( ) ; if ( $ oExecutingModuleSpot ) { $ sSpotName = $ oExecutingModuleSpot -> sModuleSpotName ; if ( array_key_exists ( $ sSpotName , $ _SESSION [ TdbShop :: SESSION_ACTIVE_VARIANT_ARRAY ] ) && array_key_exists ( $ sParentId , $ _SESSION [ TdbShop :: SESSION_ACTIVE_VARIANT_ARRAY ] [ $ sSpotName ] ) ) { $ sShopVariantArticleId = $ _SESSION [ TdbShop :: SESSION_ACTIVE_VARIANT_ARRAY ] [ $ sSpotName ] [ $ sParentId ] ; } } } return $ sShopVariantArticleId ; }
return the active variant for a parent article and a given spot. returns false if no
variant has been selected for that parent in the spot yet.

@param string $sParentId

@return string
return the active variant for a parent article and a given spot . returns false if no variant has been selected for that parent in the spot yet .