Context for storefront events
Functions
The following functions get and set context data.
mse.context.getCategory
Gets the Category context.
Syntax:
mse.context.getCategory();
mse.context.getCustomUrl
Gets the CustomUrl context.
Syntax:
mse.context.getCustomUrl();
mse.context.getMagentoExtension
Gets the MagentoExtension context.
Syntax:
mse.context.getMagentoExtension();
mse.context.getOrder
Gets the Order context.
Syntax:
mse.context.getOrder();
mse.context.getPage
Gets the Page context.
Syntax:
mse.context.getPage();
mse.context.getProduct
Gets the Product context.
Syntax:
mse.context.getProduct();
mse.context.getRecommendations
Gets the Recommendations context.
Syntax:
mse.context.getRecommendations();
mse.context.getReferrerUrl
Gets the ReferrerUrl context.
Syntax:
mse.context.getReferrerUrl();
mse.context.getSearchInput
Gets the SearchInput context.
Syntax:
mse.context.getSearchInput();
mse.context.getSearchResults
Gets the SearchResults context.
Syntax:
mse.context.getSearchResults();
mse.context.getShopper
Gets the Shopper context.
Syntax:
mse.context.getShopper();
mse.context.getShoppingCart
Gets the ShoppingCart context.
Syntax:
mse.context.getShoppingCart();
mse.context.getStorefrontInstance
Gets the StorefrontInstance context.
Syntax:
mse.context.getStorefrontInstance();
mse.context.getContext
Gets a custom Context.
nameContext nameSyntax:
mse.context.getContext(name);
mse.context.setCategory
Sets the Category context.
contextCategory contextSyntax:
mse.context.setCategory(categoryCtx);
mse.context.setCustomUrl
Sets the CustomUrl context.
contextCustomUrl contextSyntax:
mse.context.setCustomUrl(customUrlCtx);
mse.context.setMagentoExtension
Sets the MagentoExtension context.
contextMagentoExtension contextSyntax:
mse.context.setMagentoExtension(magentoExtensionCtx);
mse.context.setOrder
Sets the Order context.
contextOrder contextSyntax:
mse.context.setOrder(orderCtx);
mse.context.setPage
Sets the Page context.
contextPage contextSyntax:
mse.context.setPage(pageCtx);
mse.context.setProduct
Sets the Product context.
contextProduct contextSyntax:
mse.context.setProduct(productCtx);
mse.context.setRecommendations
Sets the Recommendations context.
contextRecommendations contextSyntax:
mse.context.setRecommendations(recommendationsCtx);
mse.context.setReferrerUrl
Sets the ReferrerUrl context.
contextReferrerUrl contextSyntax:
mse.context.setReferrerUrl(referrerUrlCtx);
mse.context.setSearchInput
Sets the SearchInput context.
contextSearchInput contextSyntax:
mse.context.setSearchInput(searchInputCtx);
mse.context.setSearchResults
Sets the SearchResults context.
contextSearchResults contextSyntax:
mse.context.setSearchResults(searchResultsCtx);
mse.context.setShopper
Sets the Shopper context.
contextShopper contextSyntax:
mse.context.setShopper(shopperCtx);
mse.context.setShoppingCart
Sets the ShoppingCart context.
contextShoppingCart contextSyntax:
mse.context.setShoppingCart(shoppingCartCtx);
mse.context.setStorefrontInstance
Sets the StorefrontInstance context.
contextStorefrontInstance contextSyntax:
mse.context.setStorefrontInstance(storefrontCtx);
mse.context.setContext
Sets a custom Context.
namenamecontextSyntax:
mse.context.setContext(ctx);