function theme_commerce_avatax_address in Drupal Commerce Connector for AvaTax 7.4
Same name and namespace in other branches
- 7.5 commerce_avatax.module \theme_commerce_avatax_address()
Format address array to be used in the address suggestion form.
2 theme calls to theme_commerce_avatax_address()
- commerce_avatax_address_compare in ./
commerce_avatax.module - Compare entered address and the address returned by AvaTax.
- commerce_avatax_address_suggestion_form in ./
commerce_avatax.module - Returns address suggestion form.
File
- ./
commerce_avatax.module, line 1106 - Calculate Sales Tax using AvaTax service from Avalara, Inc.
Code
function theme_commerce_avatax_address($variables) {
$addr = $variables['address'];
$output = $addr['line1'] . '<br />';
if ($addr['line2']) {
$output .= $addr['line2'] . '<br />';
}
$output .= $addr['city'] . '<br />' . $addr['state'] . ' ' . $addr['postal_code'] . '<br />' . $addr['country'];
return $output;
}