本文整理汇总了PHP中zen_address_format函数的典型用法代码示例。如果您正苦于以下问题:PHP zen_address_format函数的具体用法?PHP zen_address_format怎么用?PHP zen_address_format使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了zen_address_format函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: zen_address_label
function zen_address_label($customers_id, $address_id = 1, $html = false, $boln = '', $eoln = "\n")
{
global $gBitDb;
$address_query = "SELECT `entry_firstname` as `firstname`, `entry_lastname` as `lastname`,\n `entry_company` as `company`, `entry_street_address` as `street_address`,\n `entry_suburb` as `suburb`, `entry_city` as `city`, `entry_postcode` as `postcode`,\n `entry_state` as `state`, `entry_zone_id` as `zone_id`,\n `entry_country_id` as `country_id`\n FROM " . TABLE_ADDRESS_BOOK . "\n WHERE `customers_id` = ? AND `address_book_id` = ?";
$address = $gBitDb->query($address_query, array((int) $customers_id, (int) $address_id));
$format_id = zen_get_address_format_id($address->fields['country_id']);
return zen_address_format($format_id, $address->fields, $html, $boln, $eoln);
}
示例2: while
?>
<?php
while (!$addresses->EOF) {
if ($addresses->fields['address_book_id'] == $_SESSION['sendto']) {
echo ' <div id="defaultSelected" class="moduleRowSelected">' . "\n";
} else {
echo ' <div class="moduleRow">' . "\n";
}
?>
<div class="back"><?php
echo zen_draw_radio_field('address', $addresses->fields['address_book_id'], $addresses->fields['address_book_id'] == $_SESSION['sendto'], 'id="name-' . $addresses->fields['address_book_id'] . '"');
?>
</div>
<div class="back"><label for="name-<?php
echo $addresses->fields['address_book_id'];
?>
"><?php
echo zen_output_string_protected($addresses->fields['firstname'] . ' ' . $addresses->fields['lastname']);
?>
</label></div>
</div>
<br class="clearBoth" />
<address><?php
echo zen_address_format($format_id, $addresses->fields, true, ' ', '<br />');
?>
</address>
<?php
$addresses->MoveNext();
}
示例3: mysql_free_result
}
}
mysql_free_result($result);
$sql = "SELECT DATE_FORMAT(date_purchased, '%m/%d/%Y') FROM orders WHERE orders_id = {$oID}";
$result = mysql_query($sql, $zen);
$date_purchased_result = mysql_fetch_assoc($result);
$date_purchased = array_pop($date_purchased_result);
mysql_free_result($result);
$sql = "SELECT * FROM " . TB_PREF . "debtors_master WHERE name=" . db_escape($order['customers_name']);
$result = db_query($sql, "Could not find customer by name");
if (db_num_rows($result) == 0) {
display_notification("Customer " . db_escape($order['customers_name']) . " not found");
break;
}
$customer = db_fetch_assoc($result);
$addr = db_escape(zen_address_format($zen, $order, 'delivery_'));
$sql = "SELECT * FROM " . TB_PREF . "cust_branch WHERE debtor_no =" . $customer['debtor_no'] . " AND br_address = " . $addr;
$result = db_query($sql, "could not find customer branch");
if (db_num_rows($result) == 0) {
$debtor_no = $customer['debtor_no'];
$sql = "SELECT * FROM " . TB_PREF . "cust_branch WHERE debtor_no = {$debtor_no}";
$result = db_query($sql, "could not find any customer branch");
$old_branch = db_fetch_assoc($result);
$sql_new = "INSERT INTO " . TB_PREF . "cust_branch (debtor_no, br_name, br_address, area, salesman, " . "contact_name, default_location, tax_group_id, sales_account, " . "sales_discount_account, receivables_account, payment_discount_account, br_post_address, branch_ref) " . "VALUES ({$debtor_no}, '" . $customer['name'] . "', {$addr}, '" . $old_branch['area'] . "', '" . $old_branch['salesman'] . "', '" . $old_branch['contact_name'] . "', '" . $old_branch['default_location'] . "', 1, '" . $old_branch['sales_account'] . "', '" . $old_branch['sales_discount_account'] . "', '" . $old_branch['receivables_account'] . "', '" . $old_branch['payment_discount_account'] . "', {$addr}, '" . $customer['name'] . "')";
db_query($sql_new, "The customer branch could not be added 2");
$result = db_query($sql, "could not find customer branch");
}
$branch = db_fetch_assoc($result);
$cart = new Cart(30);
// New Sales Order
$cart->customer_id = $customer['debtor_no'];
示例4: zen_draw_radio_field
if ($addresses->fields['address_book_id'] == $_SESSION['sendto']) {
echo '<div class="col-lg-6 col-md-6 col-sm-6 col-xs-12"><div id="defaultSelected" class="moduleRowSelected">' . "\n";
} else {
echo ' <div class="col-lg-6 col-md-6 col-sm-6 col-xs-12"><div class="moduleRow">' . "\n";
}
?>
<div class="back">
<?php
echo zen_draw_radio_field('address', $addresses->fields['address_book_id'], $addresses->fields['address_book_id'] == $_SESSION['sendto'], 'id="name-' . $addresses->fields['address_book_id'] . '"');
?>
<span class="add_title" style="margin-left:5px">
<label for="name-<?php
echo $addresses->fields['address_book_id'];
?>
"><?php
echo zen_output_string_protected($addresses->fields['firstname'] . ' ' . $addresses->fields['lastname']);
?>
</label>
</span>
</div>
<address>
<?php
echo zen_address_format(zen_get_address_format_id($addresses->fields['country_id']), $addresses->fields, true, ' ', '<br />');
?>
</address>
</div> </div> <!--end of divs in while loop -->
<?php
$addresses->MoveNext();
}
?>
</div>
示例5: CommerceCommission
<?php
$gBitSystem->verifyPermission('p_bitcommerce_retailer');
require_once BITCOMMERCE_PKG_PATH . 'classes/CommerceCommission.php';
if (count($_GET) > 2 || count($_POST) > 2) {
$gBitUser->verifyTicket();
}
$commissionManager = new CommerceCommission();
if (!empty($_REQUEST['save_commission_settings'])) {
$gBitUser->storePreference('commissions_payment_method', $_REQUEST['commissions_payment_method']);
if (!empty($_REQUEST['commissions_' . $_REQUEST['commissions_payment_method'] . '_address'])) {
$gBitUser->storePreference('commissions_' . $_REQUEST['commissions_payment_method'] . '_address', $_REQUEST['commissions_' . $_REQUEST['commissions_payment_method'] . '_address']);
}
}
$gBitSmarty->assign_by_ref('commissionList', $commissionManager->getHistory(array('user_id' => $gBitCustomer->mCustomerId)));
if ($addresses = $gBitCustomer->getAddresses()) {
foreach ($addresses as $addrId => $addr) {
$addressList[$addr['address_book_id']] = zen_address_format(zen_get_address_format_id($addr['country_id']), $addr, 0, ' ', ' ');
}
$gBitSmarty->assign_by_ref('addressList', $addressList);
$gBitSmarty->assign('defaultAddressId', $gBitUser->getPreference('commissions_check_address', $gBitCustomer->getDefaultAddress()));
}
$paymentOptions[''] = tra('Please Select Below...');
$paymentOptions['storecredit'] = tra('Store Credit');
$paymentOptions['paypal'] = tra('PayPal');
$paymentOptions['worldpay'] = tra('WorldPay');
$paymentOptions['check'] = tra('Check');
$gBitSmarty->assign('paymentOptions', $paymentOptions);
define('HEADING_TITLE', tra('Commissions'));
$gBitSmarty->display('bitpackage:bitcommerce/commissions.tpl');
示例6: zen_address_format
<td class="main"><?php
echo '<a href="mailto:' . $order->customer['email_address'] . '">' . $order->customer['email_address'] . '</a>';
?>
</td>
</tr>
</table></td>
<td valign="top"><table width="100%" border="0" cellspacing="0" cellpadding="2">
<tr>
<td class="main"><b><?php
echo ENTRY_SHIP_TO;
?>
</b></td>
</tr>
<tr>
<td class="main"><?php
echo zen_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br>');
?>
</td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
<tr>
<td><?php
echo zen_draw_separator('pixel_trans.gif', '1', '10');
?>
</td>
</tr>
<tr>
<td class="main"><b><?php
示例7: zen_address_format
<?php
} else {
// temporary just remove these 4 lines
?>
<div>WARNING: Missing Shipping Information</div>
<?php
}
?>
</div>
<div id="myAccountPaymentInfo" class="floatingBox forward">
<h3><?php
echo HEADING_BILLING_ADDRESS;
?>
</h3>
<address><?php
echo zen_address_format($order->billing['format_id'], $order->billing, 1, ' ', '<br />');
?>
</address>
<h4><?php
echo HEADING_PAYMENT_METHOD;
?>
</h4>
<div><?php
echo $order->info['payment_method'];
?>
</div>
</div>
<br class="clearBoth" />
</div>
示例8: foreach
<div class="panel-title"><?php
echo PRIMARY_ADDRESS_TITLE;
?>
</div>
<div class="row">
<?php
foreach ($addressArray as $addresses) {
?>
<div class="col-xs-6 col-sm-6 col-md-6">
<h3 class="addressBookDefaultName"><?php
echo zen_output_string_protected($addresses['firstname'] . ' ' . $addresses['lastname']);
?>
</h3>
<address><?php
echo zen_address_format($addresses['format_id'], $addresses['address'], true, ' ', '<br />');
?>
</address>
<div class="form-inline">
<a class="btn btn-default" href="<?php
echo zen_href_link(FILENAME_ADDRESS_BOOK_PROCESS, 'edit=' . $addresses['address_book_id'], 'SSL');
?>
"><?php
echo BUTTON_EDIT_SMALL_ALT;
?>
</a>
<a class="btn btn-default" href="<?php
echo zen_href_link(FILENAME_ADDRESS_BOOK_PROCESS, 'delete=' . $addresses['address_book_id'], 'SSL');
?>
"><?php
echo BUTTON_DELETE_ALT;
示例9: zen_address_format
<td valign="top"><table border="0" cellpadding="2" cellspacing="0">
<tr>
<td class="printMain" valign="top"><strong><?php echo ENTRY_CUSTOMER_ADDRESS; ?></strong></td>
<td class="printMain"><?php echo zen_address_format($order->customer['format_id'], $order->customer, 1, '', '<br />'); ?></td>
</tr>
</table></td>
<td valign="top"><table border="0" cellpadding="2" cellspacing="0">
<tr>
<td class="printMain" valign="top"><strong><?php echo ENTRY_SHIPPING_ADDRESS; ?></strong></td>
<td class="printMain"><?php echo zen_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br />'); ?></td>
</tr>
</table></td>
<td valign="top"><table border="0" cellpadding="2" cellspacing="0">
<tr>
<td class="printMain" valign="top"><strong><?php echo ENTRY_BILLING_ADDRESS; ?></strong></td>
<td class="printMain"><?php echo zen_address_format($order->billing['format_id'], $order->billing, 1, '', '<br />'); ?></td>
</tr>
</table></td>
</tr>
</table></td>
</tr>
<tr>
<td><table border="0" cellpadding="2" cellspacing="0">
<tr>
<td class="printMain"><strong><?php echo ENTRY_TELEPHONE_NUMBER; ?></strong></td>
<td class="printMain"><?php echo $order->customer['telephone']; ?></td>
</tr>
<tr>
<td class="printMain"><strong><?php echo ENTRY_EMAIL_ADDRESS; ?></strong></td>
<td class="printMain"><?php echo $order->customer['email_address']; ?></td>
</tr>
示例10: zen_draw_separator
</tr>
</table></td>
<td><?php
echo zen_draw_separator('pixel_trans.gif', '175', '1');
?>
</td>
<td align="right" valign="top"><table border="0" cellpadding="2" cellspacing="0" width="100%">
<tr>
<td class="main"><strong><?php
echo ENTRY_SOLD_TO;
?>
</strong></td>
</tr>
<tr>
<td class="main"><?php
echo zen_address_format($order->customer['format_id'], $order->billing, 1, '', '<br>');
?>
</td>
</tr>
</table></td>
</tr>
</table>
</td>
</tr>
</table></td>
</tr>
<tr>
<td><?php
echo zen_draw_separator('pixel_trans.gif', '1', '10');
?>
</td>
示例11: zen_get_address_fields
</div>
</li>
<?php
// ** BEGIN PAYPAL EXPRESS CHECKOUT **
if (!$payment_modules->in_special_checkout()) {
// ** END PAYPAL EXPRESS CHECKOUT **
?>
<li>
<div id="checkoutBillto" class="margin_t big_">
<ul>
<?php
$billToArray = zen_get_address_fields($_SESSION['customer_id'], $_SESSION['billto']);
echo '<b>' . $billToArray['firstname'] . ' ' . $billToArray['lastname'] . '</b>';
$billToArrayFiltered = filterName($billToArray);
$format_id_bill = zen_get_address_format_id($billToArrayFiltered['country_id']);
echo zen_address_format($format_id_bill, $billToArrayFiltered, true, ' ', '<br />');
echo '<br/>Phone: ' . $billToArray['phone'];
?>
</ul>
<?php
if (MAX_ADDRESS_BOOK_ENTRIES >= 2) {
?>
<ul class="pad_l_90px margin_t"><?php
echo '<a href="' . zen_href_link(FILENAME_ADDRESS_BOOK_PROCESS, 'url=checkout_shipping&edit=' . $_SESSION['billto'], 'SSL') . '">' . zen_image($template->get_template_dir('btn_edit.gif', DIR_WS_TEMPLATE, $current_page_base, 'images/button') . '/btn_edit.gif', '', '', '', ' border="0"') . '</a>';
?>
</ul>
<?php
}
?>
</div>
<br class="clearBoth" />
示例12: zen_image
<li class="fl">
<?php
echo '<a class="pad_b2" href="javascript:document.checkout_address.address.value=\'' . $addresses->fields['address_book_id'] . '\';document.checkout_address.submit();" >';
echo zen_image($template->get_template_dir('btn_ship.gif', DIR_WS_TEMPLATE, $current_page_base, 'images/button') . '/btn_ship.gif');
echo '</a>';
?>
<div class="pad_l">
<b><?php
echo zen_output_string_protected($addresses->fields['firstname'] . ' ' . $addresses->fields['lastname']);
?>
</b>
<?php
$array_filtered = filterName($addresses->fields);
?>
<?php
echo zen_address_format($format_id, $array_filtered, true, ' ', '<br />');
echo '<br />Phone:' . $addresses->fields['phone'];
?>
<ul class="pad_top">
<a href="<?php
echo zen_href_link(FILENAME_ADDRESS_BOOK_PROCESS, 'edit=' . $addresses->fields['address_book_id']);
?>
">
<?php
echo zen_image($template->get_template_dir('btn_edit.gif', DIR_WS_TEMPLATE, $current_page_base, 'images/button') . '/btn_edit.gif');
?>
</a>
<?php
if ($i != 0) {
?>
示例13: getFormattedAddress
function getFormattedAddress($pAddressHash, $pBreak = '<br>')
{
$ret = '';
if ($this->isValid()) {
$ret = zen_address_format(BitBase::getParameter($this->{$pAddressHash}, 'format_id', 2), $this->{$pAddressHash}, 1, '', $pBreak);
}
return $ret;
}
示例14: zen_draw_separator
<td class="main"><?php echo '<a href="mailto:' . $order->customer['email_address'] . '">' . $order->customer['email_address'] . '</a>'; ?></td>
</tr>
</table></td>
<td><?php echo zen_draw_separator('pixel_trans.gif', '60', '1'); ?></td>
<td valign="top"><table border="0" cellpadding="2" cellspacing="0" width="100%">
<tr>
<td><?php echo zen_draw_separator('pixel_trans.gif', '1', '5'); ?></td>
</tr>
<tr>
<td class="main"><strong><?php echo ENTRY_SHIP_TO; ?></strong></td>
</tr>
<tr>
<td><?php echo zen_draw_separator('pixel_trans.gif', '1', '5'); ?></td>
</tr>
<tr>
<td class="main"><?php echo zen_address_format($order->delivery['format_id'], $order->delivery, 1, '', '<br>'); ?></td>
</tr>
</table></td>
<?php
if ($so->purchase_order) {
?>
<td align="right" valign="top"><table border="0" cellpadding="2" cellspacing="0">
<tr>
<td><?php echo zen_draw_separator('pixel_trans.gif', '1', '5'); ?></td>
</tr>
<tr>
<td class="main" colspan="2"><strong><?php echo ENTRY_PO_INFO; ?></strong></td>
</tr>
<tr>
<td><?php echo zen_draw_separator('pixel_trans.gif', '1', '5'); ?></td>
</tr>
示例15: zen_output_string_protected
<td width="10%" class="alignright fontbold"><?php
echo NAME;
?>
</td>
<td><?php
echo zen_output_string_protected($addresses['firstname'] . ' ' . $addresses['lastname']);
?>
</td>
</tr>
<tr>
<td width="10%" class="alignright fontbold"><?php
echo ADDRESS;
?>
</td>
<td><?php
$tmp_addr = zen_address_format($addresses['format_id'], $addresses['address'], true, ' ', ' ');
$tmp_addr = str_replace($addresses['firstname'], '', $tmp_addr);
$tmp_addr = str_replace($addresses['lastname'], '', $tmp_addr);
$tmp_addr = preg_replace("/( )*/", '', $tmp_addr);
echo trim($tmp_addr);
?>
</td>
</tr>
<tr>
<td width="10%" class="alignright fontbold"><?php
echo TELEPHONE;
?>
</td>
<td><?php
echo $addresses['address']['telphone'];