function autosave_address($info, &$address = NULL) { format_address($address); verify_address($error, $address); if ($error) { return $error; } $save_type = isset($address['save_type']) ? $address['save_type'] : 0; switch ($save_type) { case 'new': if (find_similar_addresses($info, $address)) { return "Similar address found."; } else { create_new_address($info, $address); } break; case 'edit': update_address($info, $address); break; default: if (find_similar_addresses($info, $address)) { update_address($info, $address); } else { create_new_address($info, $address); } } return true; }
echo lang('your_addresses'); ?> </h3> </div> <div class="modal-body"> <p> <table class="table table-striped"> <?php $c = 1; foreach ($customer_addresses as $a) { ?> <tr> <td> <?php $b = $a['field_data']; echo nl2br(format_address($b)); ?> </td> <td style="width:100px;"><input type="button" class="btn btn-primary choose_address pull-right" onclick="populate_address(<?php echo $a['id']; ?> );" data-dismiss="modal" value="<?php echo lang('form_choose'); ?> " /></td> </tr> <?php } ?> </table> </p>
<?php if (count($addresses) > 0) { ?> <div id="addressError" class="alert red hide"></div> <div class="col-nest"> <div class="col" data-cols="1"> <table class="table horizontal-border"> <tbody> <?php foreach ($addresses as $a) { ?> <tr> <td> <?php echo format_address($a, true); ?> </td> <td> <label><?php $checked = GC::getCart()->billing_address_id == $a['id'] ? true : false; echo form_radio(['name' => 'billing_address', 'value' => $a['id'], 'checked' => $checked]); echo lang('billing'); ?> </label> </td> <td> <label><?php $checked = GC::getCart()->shipping_address_id == $a['id'] ? true : false; echo form_radio(['name' => 'shipping_address', 'value' => $a['id'], 'checked' => $checked]); ?>
<div class="col-md-3"> <h3><?php echo lang('shipping_address'); ?> </h3> <?php echo format_address(['company' => $order->shipping_company, 'firstname' => $order->shipping_firstname, 'lastname' => $order->shipping_lastname, 'phone' => $order->shipping_phone, 'email' => $order->shipping_email, 'address1' => $order->shipping_address1, 'address2' => $order->shipping_address2, 'city' => $order->shipping_city, 'zone' => $order->shipping_zone, 'zip' => $order->shipping_zip, 'country_id' => $order->shipping_country_id]); ?> </div> <div class="col-md-3"> <h3><?php echo lang('billing_address'); ?> </h3> <?php echo format_address(['company' => $order->billing_company, 'firstname' => $order->billing_firstname, 'lastname' => $order->billing_lastname, 'phone' => $order->billing_phone, 'email' => $order->billing_email, 'address1' => $order->billing_address1, 'address2' => $order->billing_address2, 'city' => $order->billing_city, 'zone' => $order->billing_zone, 'zip' => $order->billing_zip, 'country_id' => $order->billing_country_id]); ?> </div> <div class="col-md-3"> <h3><?php echo lang('payment_method'); ?> </h3> <?php foreach ($order->payments as $payment) { ?> <div><?php echo $payment->description; ?> </div> <?php
<div class="span7" id='address_list'> <?php if (count($addresses) > 0) { ?> <table class="table table-bordered table-striped"> <?php $c = 1; foreach ($addresses as $a) { ?> <tr id="address_<?php echo $a['id']; ?> "> <td><?php $b = $a['field_data']; echo format_address($b, true); ?> </td> <td> <div class="row-fluid"> <div class="span12"> <div class="btn-group pull-right"> <input type="button" class="btn edit_address" rel="<?php echo $a['id']; ?> " value="<?php echo lang('form_edit'); ?> " /> <input
?> <br/> <?php echo $ship['phone']; ?> </div> <?php if ($ship != $bill) { ?> <div class="span4"> <h3><?php echo lang('billing_information'); ?> </h3> <?php echo format_address($bill, TRUE); ?> <br/> <?php echo $bill['email']; ?> <br/> <?php echo $bill['phone']; ?> </div> <?php } ?> </div>
<div class="col span_6_of_7"> <div class="content-container"> <form name="checkOut" id="checkOut" method="post" action="<?php echo site_url('checkout/place_order'); ?> "> <h1>Check Out Confirm</h1> <div class="col span_7_of_7"> <?php if (!empty($customer['bill_address'])) { ?> <div class="address"> Address <p> <?php echo format_address($customer['bill_address'], true); ?> </p> <p> <?php echo $customer['bill_address']['phone']; ?> <br/> <?php echo $customer['bill_address']['email']; ?> </p> </div> <?php } ?>
<th>Mode</th> <th>Amount</th> <th>Date</th> <th>Waybill</th> <?php foreach ($requested_shipments as $key => $shipment) { ?> <tr> <td> <?php echo $shipment['txn_id']; ?> </td> <td> <?php echo format_address($shipment['address']); ?> </td> <td> <?php echo $shipment['payment_mode']; ?> </td> <td> <?php echo $shipment['order_amount']; ?> </td> <td> <?php echo $shipment['date_created'];
function contact() { $data['return_address'] = format_address($this->config->item('return_address')); display('contact', $data); }
?> </span></div> <div class="row"> <?php $ship = $customer['ship_address']; $bill = $customer['bill_address']; ?> <div style="font-family: 'Georgia', serif; font-size:14px; font-weight:bold; text-align:left;"> <div style="clear:both; color: #412D1A !important; font-family: 'BebasNeueRegular',Arial,sans-serif; font-size: 18px; padding: 15px 0 15px 0; text-align:left;"><?php echo $ship != $bill ? 'Shipping Information' : 'Shipping And Billing'; ?> </div> <?php echo format_address($ship, TRUE); ?> <br/> <?php echo $ship['email']; ?> <br/> <?php echo $ship['phone']; ?> <br> </div> <?php if ($ship != $bill) { ?> <div style="font-family: 'Georgia', serif; font-size:14px; font-weight:bold; text-align:left;">
if (config_item('require_shipping')) { ?> <?php if ($this->jcart->requires_shipping()) { ?> <div class="span3"> <a href="<?php echo site_url('checkout/shipping_address'); ?> " class="btn btn-block"><?php echo lang('shipping_address_button'); ?> </a> <p> <?php echo format_address($customer['ship_address'], true); ?> </p> <p> <?php echo $customer['ship_address']['phone']; ?> <br/> <?php echo $customer['ship_address']['email']; ?> <br/> </p> </div> <?php
$custom_fields = get_post_custom(); list($address) = $custom_fields['address']; list($phone) = $custom_fields['phone']; ?> <address> <?php if ($address) { ?> <div title="<?php echo __('Address'); ?> "><i class="fa fa-map-marker"></i> <?php echo format_address($address); ?> </div> <?php } ?> <?php if ($phone) { ?> <div><a title="<?php echo __('Phone'); ?> " href="tel:<?php echo telephone_subscriber($phone); ?>
<thead> <tr> <th>Clinic</th> <th>Address</th> <th>Type</th> <th>Services</th> <th>Hours</th> <th>Phone</th> <th>Website</th> </tr> </thead> <tbody> <?php foreach ($result as $i => $row) { if ($i > 0) { echo "\n\t\t<tr>\n\t\t<td>{$row['0']}</td>\n\t\t<td>" . format_address($row[3], $row[4], $row[5], $row[6]) . "</td>\n\t\t<td>{$row['10']}</td>\n\t\t<td>{$row['9']}</td>\n\t\t<td>{$row['2']}</td>\n\t\t<td>{$row['7']}</td>\n\t\t<td><a href='{$row['8']}'>Website</a></td>\n\t\t</tr>"; } } /* //use this to print out all columns and rows //print table head echo "<thead><tr>\n"; foreach ($csvArr[0] as $i => $col) { echo "<th>$col</th>\n"; } echo "</tr></thead>\n"; //print table body echo "<tbody>\n"; foreach ($csvArr as $i => $row) { if ($i > 0)
function formatted_address() { return format_address($this->address1, $this->address2, $this->city, $this->state_prov, $this->postal_code); }
function get_address_by_contact_id($cid = 0, $output_type = 'both', $address_tag = TRUE) { if (!$cid) { return FALSE; } $CI =& get_instance(); $CI->load->model('address_model'); $address = $CI->address_model->get_address_by_contact_id($cid); if (!count($address)) { return FALSE; } if (strcmp($output_type, 'data') === 0) { return $address; } $address_format = format_address($address, $address_tag); if (strcmp($output_type, 'html') === 0) { return $address_format; } return array('data' => $address, 'html' => $address_format); }
function _generate_checkout_table($orders) { $this->load->library('table'); $this->table->set_heading('#', 'Txn_id', 'Date', 'Email', 'Address', 'Amount', 'State', 'Remind', 'Delete'); $tmpl = array('table_open' => '<table class="table table-condensed" >'); $this->table->set_template($tmpl); $num = 1; foreach ($orders as $order) { if (is_null($order)) { continue; } $txn_id = $order['txn_id']; $address = "null"; $date = $order['date_created']; $amount = $order['order_amount']; $state = $order['state']; $reminder_mail_link = null; $email = "null"; if (count($order['address'])) { $address = format_address($order['address']); } if (count($order['user'])) { $email = $order['user']['email']; $email = $email; $product_id = null; foreach ($order['order_items'] as $key => $item) { $product_id[] = $item['product']['product_id']; } $product_id = implode('-', $product_id); $user_id = $order['user']['id']; $remind_url = site_url("admin/remind/{$user_id}/{$product_id}"); $reminder_mail_link = "<a class ='btn btn-danger' href={$remind_url}> Remind </a>"; } $delete_url = site_url("admin/delete_checkout/{$txn_id}"); $delete_link = "<a class ='btn btn-warning' href={$delete_url}> Delete Checkout </a>"; $this->table->add_row($num, $txn_id, $date, $email, $address, $amount, $state, $reminder_mail_link, $delete_link); if (isset($order['order_items'])) { foreach ($order['order_items'] as $key => $item) { $product = $item['product']; $product_name = array('data' => $product['product_name'], 'colspan' => 4, 'align' => 'right'); $size = array('data' => $item['size'], 'colspan' => 2, 'align' => 'right'); $count = array('data' => $item['count'], 'colspan' => 2, 'align' => 'right'); $this->table->add_row($product_name, $size, $count); } } ++$num; } return $this->table->generate(); }