Run an external script as a particular Magento user
I'm running a Magento site that has different prices for different user groups.
I'd like to put together a feed that shows the prices for a particular group. I've put together an external script that produces the feed, but don't see any way to set the user or set the group within the Magento session that the script is running under.
How would I go about this?开发者_StackOverflow社区
You can get the price that will be after rules are applied with the following code -
Mage::getResourceModel('catalogrule/rule')
->getRulePrice($date, $websiteId, $groupId, $productId);
精彩评论