2011-04-29 55 views
1

用户来签并选择注册新的客户,在下订单的时候,我想获得信息,他/她进入这样的:获取结账单后登记客户信息被放置

 
//This is in Paypal Standard Model 
$quote = $this->getQuote(); 
$isQuoteVirtual = $quote->getIsVirtual(); 
$address = $isQuoteVirtual ? $quote->getBillingAddress() : $quote->getShippingAddress(); 

//City: 
$address->getCity(); 

//Country Code: 
$address->getCountryId(); 

这在客户登录时起作用,但是当他/她选择注册时,这个信息不可用,因为它没有保存在sales_flat_quote_address表中,有没有办法让我在这一点上获取客户信息?我可以在会话中使用或存储任何钩子,或者有更优雅的处理方式。 预先感谢您。

+0

和方式,我正在使用Magento 1.4.0.1版本 – zokibtmkd 2011-04-29 17:03:29

+1

,你在哪里试图获取这些信息? – 2011-04-29 21:36:59

+0

我用我自己的方法覆盖了Paypal标准模型:类Zoran_Paypal_Model_Standard扩展了Mage_Paypal_Model_Standard,我使用的方法是:getStandardCheckoutFormFields(),在用户下订单后执行。 – zokibtmkd 2011-04-30 09:06:47

回答