?>
</td>
                <td class="main" width="50%" valign="top" align="right"><?php 
        echo '<b>' . TITLE_PLEASE_SELECT . '</b><br>' . smn_image(DIR_WS_IMAGES . 'arrow_east_south.gif');
        ?>
</td>
                <td><?php 
        echo smn_draw_separator('pixel_trans.gif', '10', '1');
        ?>
</td>
              </tr>
<?php 
        $radio_buttons = 0;
        $addresses_query = smn_db_query("select address_book_id, entry_firstname as firstname, entry_lastname as lastname, entry_company as company, entry_street_address as street_address, entry_city as city, entry_postcode as postcode, entry_state as state, entry_zone_id as zone_id, entry_country_id as country_id from " . TABLE_ADDRESS_BOOK . " where customers_id = '" . (int) $customer_id . "'");
        while ($addresses = smn_db_fetch_array($addresses_query)) {
            $format_id = smn_get_address_format_id($addresses['country_id']);
            ?>
              <tr>
                <td><?php 
            echo smn_draw_separator('pixel_trans.gif', '10', '1');
            ?>
</td>
                <td colspan="2"><table border="0" width="100%" cellspacing="0" cellpadding="2">
<?php 
            if ($addresses['address_book_id'] == $sendto) {
                echo '                  <tr id="defaultSelected" class="moduleRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";
            } else {
                echo '                  <tr class="moduleRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="selectRowEffect(this, ' . $radio_buttons . ')">' . "\n";
            }
            ?>
                    <td width="10"><?php 
Example #2
0
function smn_address_label($customers_id, $address_id = 1, $html = false, $boln = '', $eoln = "\n")
{
    if (is_array($address_id) && !empty($address_id)) {
        return smn_address_format($address_id['address_format_id'], $address_id, $html, $boln, $eoln);
    }
    $address_query = smn_db_query("select entry_firstname as firstname, entry_lastname as lastname, entry_company as company, entry_street_address as street_address, entry_city as city, entry_postcode as postcode, entry_state as state, entry_zone_id as zone_id, entry_country_id as country_id from " . TABLE_ADDRESS_BOOK . " where customers_id = '" . (int) $customers_id . "' and address_book_id = '" . (int) $address_id . "'");
    $address = smn_db_fetch_array($address_query);
    $format_id = smn_get_address_format_id($address['country_id']);
    return smn_address_format($format_id, $address, $html, $boln, $eoln);
}