Posting in the Magento forums has been disabled pending the implementation of a new and improved forum solution which should better serve the community.

For new questions please post at magento.stackexchange.com, the community-run support site for the Magento community. We will be providing updates on the new forum solution soon. For questions or concerns please email community@magento.com.

Magento Forum

Pulling out Address information in the payment form
 
Sam Boson
Jr. Member
 
Avatar
Total Posts:  24
Joined:  2007-11-15
 

I’m trying to create a payment form which will then submit the order information to an external site for processing.

The problem is that when I’m retrieving the address information it’s failing on the first pass, If I’ve already entered the information before it will retrieve that. It always seems one step behind. I presume the data I am accessing is the saved data and what I want is the current information but I’m not sure how to obtain that. I’m using the progress block controller to access both shipping and billing addresses as that is the methodology used in the progress block.

Please help I’ve been banging my head against a brick wall for a couple of days and it’s starting to hurt.

This is the code I have been using it is contained within the Block ‘helper’ for my payment form.

public function getQuote()
    
{
        
if (empty($this->_quote)) {
            $this
->_quote $this->getCheckout()->getQuote();
        
}

        
return $this->_quote;
    
}

    
public function getBillingArray()
    
{
        $address 
= array();
        
$billing $this->getQuote()->getBillingAddress();

        return 
$billing;
    
}

    
public function getShippingArray()
    
{
        $address 
= array();
        
$shipping $this->getQuote()->getShippingAddress();

        return 
$shipping;
    
}
 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
Back to top