Hi,
I am making a site where the prices (taxes) will change based on shipping country. I want to show the correct price on the product pages and the user are on first visit asked for shipping country and I store this in a cookie. But, for logged in users with a stored address it would be very useful to buypass this question and retrieve the stored shipping country.
I have briefly looked at commerce_addressbook.module and found the commerce_addressbook_get_default_profile_id function that retrieves the ID of the profile, but is there an easy way to retrieve the default shipping address for example?
Comments
Comment #1
mglamanYou would do something like the following snippet to get addressfield data.