• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

PHP format_currency函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了PHP中format_currency函数的典型用法代码示例。如果您正苦于以下问题:PHP format_currency函数的具体用法?PHP format_currency怎么用?PHP format_currency使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了format_currency函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。

示例1: price_for

function price_for($rt_shop_product, $config = array())
{
    $format_was = '<span class="price-before">%s<em>%s</em></span>';
    $format_now = '<span class="price-now">%s<em>%s</em></span>';
    $config['format_was'] = isset($config['format_was']) ? $config['format_was'] : $format_was;
    $config['format_now'] = isset($config['format_now']) ? $config['format_now'] : $format_now;
    $config['format_now_preffix_from'] = isset($config['format_now_preffix_from']) ? $config['format_now_preffix_from'] : __('From') . ' ';
    $config['format_now_preffix_only'] = isset($config['format_now_preffix_only']) ? $config['format_now_preffix_only'] : '';
    $config['format_now_preffix_now_only'] = isset($config['format_now_preffix_now_only']) ? $config['format_now_preffix_now_only'] : __('Now') . ' ';
    $config['format_now_preffix_now_from_only'] = isset($config['format_now_preffix_now_from_only']) ? $config['format_now_preffix_now_from_only'] : __('Now') . ' ';
    // This might need to be changes to "Now from"?
    $config['format_was_preffix'] = isset($config['format_was_preffix']) ? $config['format_was_preffix'] : __('Was') . ' ';
    $currency = sfConfig::get('app_rt_currency', 'USD');
    $price_min = $rt_shop_product->isOnPromotion() ? $rt_shop_product->getMinimumPrice() : $rt_shop_product->getMinRetailPrice();
    $price_max = max($rt_shop_product->getMaxRetailPrice(), $rt_shop_product->getMaxPromotionPrice());
    if (!$rt_shop_product->isOnPromotion()) {
        return sprintf($config['format_now'], $price_min != $price_max ? $config['format_now_preffix_from'] : $config['format_now_preffix_only'], format_currency($price_min, $currency));
    }
    $string = '';
    $retail_prices_match = $rt_shop_product->getMaxRetailPrice() == $rt_shop_product->getMinRetailPrice();
    $promo_prices_match = $rt_shop_product->getMaxPromotionPrice() == $rt_shop_product->getMinPromotionPrice();
    if ($retail_prices_match) {
        $string = sprintf($config['format_was'], $config['format_was_preffix'], format_currency($price_max, $currency));
    }
    $string .= ' ' . sprintf($config['format_now'], $promo_prices_match ? $config['format_now_preffix_now_only'] : $config['format_now_preffix_now_from_only'], format_currency($price_min, $currency));
    return $string;
}
开发者ID:pierswarmers,项目名称:rtShopPlugin,代码行数:27,代码来源:rtShopProductHelper.php


示例2: format_currency

 protected function format_currency($floatcurr, $curr = 'USD')
 {
     if (defined('STRICT_TYPES') && CAMEL_CASE == '1') {
         return (string) self::parameters(['floatcurr' => [DT::INT64, DT::UINT64, DT::FLOAT], 'curr' => DT::STRING])->call(__FUNCTION__)->with($floatcurr, $curr)->returning(DT::STRING);
     } else {
         return (string) format_currency($floatcurr, $curr);
     }
 }
开发者ID:tfont,项目名称:skyfire,代码行数:8,代码来源:math.class.php


示例3: modal_product_lookups_json

 /**
  * pZ: modal_product_lookups_json
  *
  */
 public function modal_product_lookups_json()
 {
     $this->load->model('mdl_products');
     $products = $this->mdl_products->get()->result();
     $data = array();
     foreach ($products as $product) {
         $data[] = array('ProductName' => $product->product_name, 'ProductFormatPrice' => format_currency($product->product_price), 'ProductPrice' => format_amount($product->product_price));
     }
     echo json_encode($data);
 }
开发者ID:lukasz-schab,项目名称:DeskdooInvoices,代码行数:14,代码来源:ajax.php


示例4: get_all_value

 public function get_all_value()
 {
     $value = array('gia_bon_dung' => $this->gia_bon_dung, 'gia_ong_dan_dau' => $this->gia_ong_dan_dau, 'gia_tu_bom' => $this->gia_tu_bom, 'gia_ong_khoi' => $this->gia_ong_khoi * $this->gen_number, 'gia_ong_nhung_non_che' => $this->gia_ong_nhung_non_che * $this->gen_number, 'gia_cap_dong_luc' => $this->gia_cap_dong_luc * $this->gen_number, 'gia_cap_te' => $this->gia_cap_te * $this->gen_number, 'gia_cap_dieu_khien' => $this->gia_cap_dieu_khien * $this->gen_number, 'gia_bao_ve_cap' => $this->gia_bao_ve_cap, 'gia_nhien_lieu_chay_nt' => $this->gia_nhien_lieu_chay_nt * $this->gen_number, 'gia_vat_tu_phu' => $this->gia_vat_tu_phu * $this->gen_number, 'gia_kiem_dinh' => $this->gia_kiem_dinh, 'gia_nhan_cong' => $this->gia_nhan_cong * $this->gen_number, 'gia_vc_duong_ngan' => $this->gia_vc_duong_ngan, 'gia_vc_duong_dai' => $this->gia_vc_duong_dai, 'gia_vc_thu_cong' => $this->gia_vc_thu_cong, 'gia_ats' => $this->gia_ats, 'gia_thoat_nhiet' => $this->gia_thoat_nhiet, 'gia_lam_gio' => $this->gia_lam_gio);
     $total_price = 0;
     foreach ($value as $price) {
         $total_price = $total_price + $price;
     }
     $parameters = array('kVA' => $this->kVA, 'phase' => $this->phase, 'gen_number' => $this->gen_number, 'total_money' => $total_price, 'total_price' => format_currency($total_price), 'gia_bon_dung_price' => format_currency($this->gia_bon_dung), 'gia_ong_dan_dau_price' => format_currency($this->gia_ong_dan_dau), 'gia_tu_bom_price' => format_currency($this->gia_tu_bom), 'gia_ong_khoi_price' => format_currency($this->gia_ong_khoi), 'gia_ong_nhung_non_che_price' => format_currency($this->gia_ong_nhung_non_che), 'gia_cap_dong_luc_price' => format_currency($this->gia_cap_dong_luc), 'gia_cap_te_price' => format_currency($this->gia_cap_te), 'gia_cap_dieu_khien_price' => format_currency($this->gia_cap_dieu_khien), 'gia_bao_ve_cap_price' => format_currency($this->gia_bao_ve_cap), 'gia_nhien_lieu_chay_nt_price' => format_currency($this->gia_nhien_lieu_chay_nt), 'gia_vat_tu_phu_price' => format_currency($this->gia_vat_tu_phu), 'gia_kd_cl_price' => format_currency($this->gia_kd_cl), 'gia_kd_tt3_price' => format_currency($this->gia_kd_tt3), 'gia_thu_tai_gia_price' => format_currency($this->gia_thu_tai_gia), 'gia_kiem_dinh_price' => format_currency($this->gia_kiem_dinh), 'gia_nhan_cong_price' => format_currency($this->gia_nhan_cong), 'gia_thao_ra_vo' => format_currency($this->gia_thao_ra_vo), 'gia_lap_may_price' => format_currency($this->gia_lap_may), 'gia_lap_dat_ats_price' => format_currency($this->gia_lap_dat_ats), 'gia_lap_tu_hoa_price' => format_currency($this->gia_lap_tu_hoa), 'gia_hd_sd_nt_price' => format_currency($this->gia_hd_sd_nt), 'gia_day_vao_vi_tri_dg_price' => format_currency($this->gia_day_vao_vi_tri_dg), 'gia_day_vao_vi_tri_pt_price' => format_currency($this->gia_day_vao_vi_tri_pt), 'distance' => $this->distance, 'error_distance' => $this->error_distance, 'gia_vc_duong_ngan_price' => format_currency($this->gia_vc_duong_ngan), 'gia_vc_duong_dai_price' => format_currency($this->gia_vc_duong_dai), 'gia_vc_thu_cong_price' => format_currency($this->gia_vc_thu_cong), 'gia_ats' => format_currency($this->gia_ats), 'gia_thoat_nhiet' => format_currency($this->gia_thoat_nhiet), 'gia_lam_gio' => format_currency($this->gia_lam_gio));
     //pr(array_merge($parameters, $value));exit;
     return json_encode(array_merge($parameters, $value));
 }
开发者ID:lekhangyahoo,项目名称:gonline,代码行数:11,代码来源:Setup.php


示例5: testFormatCurrency

 public function testFormatCurrency()
 {
     //        $this->markTestIncomplete('Test Incomplete.');
     //        $this->markTestSkipped('Test Skipped');
     //        $this->fail('Test fail');
     $this->assertEquals(format_currency(123.45), '123,45&nbsp;EURO', 'pos: 1');
     $this->assertEquals(format_currency(123), '123,00&nbsp;EURO', 'pos: 2');
     $this->assertEquals(format_currency(5678), '5&nbsp;678,00&nbsp;EURO', 'pos: 3');
     $this->assertEquals(format_currency(-123.1), '-123,10&nbsp;EURO', 'pos: 4');
     $this->assertEquals(format_currency(-5678.1), '-5&nbsp;678,10&nbsp;EURO', 'pos: 5');
 }
开发者ID:lukasz-schab,项目名称:DeskdooInvoices,代码行数:11,代码来源:NumberHelperTest.php


示例6: parse_template

function parse_template($object, $body)
{
    if (preg_match_all('/{{{([^{|}]*)}}}/', $body, $template_vars)) {
        foreach ($template_vars[1] as $var) {
            switch ($var) {
                case 'invoice_guest_url':
                    $replace = site_url('guest/view/invoice/' . $object->invoice_url_key);
                    break;
                case 'invoice_date_due':
                    $replace = date_from_mysql($object->invoice_date_due, TRUE);
                    break;
                case 'invoice_date_created':
                    $replace = date_from_mysql($object->invoice_date_created, TRUE);
                    break;
                case 'invoice_total':
                    $replace = format_currency($object->invoice_total);
                    break;
                case 'invoice_paid':
                    $replace = format_currency($object->invoice_paid);
                    break;
                case 'invoice_balance':
                    $replace = format_currency($object->invoice_balance);
                    break;
                case 'quote_total':
                    $replace = format_currency($object->quote_total);
                    break;
                case 'quote_date_created':
                    $replace = date_from_mysql($object->quote_date_created, TRUE);
                    break;
                case 'quote_date_expires':
                    $replace = date_from_mysql($object->quote_date_expires, TRUE);
                    break;
                case 'quote_guest_url':
                    $replace = site_url('guest/view/quote/' . $object->quote_url_key);
                    break;
                default:
                    $replace = $object->{$var};
            }
            $body = str_replace('{{{' . $var . '}}}', $replace, $body);
        }
    }
    return $body;
}
开发者ID:lukasz-schab,项目名称:DeskdooInvoices,代码行数:43,代码来源:template_helper.php


示例7: setup

 public function setup()
 {
     parent::setup();
     // Helpers
     sfContext::getInstance()->getConfiguration()->loadHelpers(array('Number'));
     // Form format
     $this->getWidgetSchema()->setFormFormatterName(sfConfig::get('app_rt_public_form_formatter_name', 'RtList'));
     // Voucher amount selection
     $options = sfConfig::get('app_rt_shop_gift_voucher_amount', array(10, 20, 25, 30, 40, 50, 75, 100, 150, 200, 300));
     // Add currency definition to amount
     $amounts = array();
     $amounts[''] = '--';
     foreach ($options as $key => $item) {
         $amounts[$item] = format_currency($item, sfConfig::get('app_rt_currency', 'USD'));
     }
     // Widgets
     $this->widgetSchema['reduction_value'] = new sfWidgetFormSelect(array('choices' => $amounts));
     $this->widgetSchema['first_name'] = new sfWidgetFormInput(array(), array());
     $this->widgetSchema['last_name'] = new sfWidgetFormInput(array(), array());
     $this->widgetSchema['email_address'] = new sfWidgetFormInput(array(), array());
     $this->widgetSchema['message'] = new sfWidgetFormTextarea(array(), array());
     // Validators
     $this->setValidator('reduction_value', new sfValidatorChoice(array('choices' => array_keys($amounts), 'required' => true), array('required' => 'Please make a selection')));
     $this->setValidator('first_name', new sfValidatorString(array('required' => true), array('required' => 'Please provide a first name')));
     $this->setValidator('last_name', new sfValidatorString(array('required' => true), array('required' => 'Please provide a last name')));
     $this->setValidator('email_address', new sfValidatorEmail(array('required' => true), array('required' => 'Please provide a valid email address')));
     $this->setValidator('message', new sfValidatorString(array('required' => false, 'max_length' => 255), array('max_length' => 'Message is too long (%max_length% characters max.)')));
     // Add labels
     $this->widgetSchema->setLabel('reduction_value', "Gift Voucher Amount");
     $this->widgetSchema->setLabel('first_name', "Recipient First Name");
     $this->widgetSchema->setLabel('last_name', "Recipient Last Name");
     $this->widgetSchema->setLabel('email_address', "Recipient Email");
     // Help texts
     $this->widgetSchema->setHelp('first_name', 'Required');
     $this->widgetSchema->setHelp('last_name', 'Required');
     $this->widgetSchema->setHelp('email_address', 'Required - The voucher will be sent here');
     $this->widgetSchema->setNameFormat('rt_shop_voucher[%s]');
     $this->errorSchema = new sfValidatorErrorSchema($this->validatorSchema);
 }
开发者ID:pierswarmers,项目名称:rtShopPlugin,代码行数:39,代码来源:rtShopVoucherPublicForm.class.php


示例8: send_notification

 function send_notification($gc_data)
 {
     $this->load->helper('formatting_helper');
     $row = $this->db->where('id', '1')->get('canned_messages')->row_array();
     // set replacement values for subject & body
     $row['subject'] = str_replace('{from}', $gc_data['from'], $row['subject']);
     $row['subject'] = str_replace('{site_name}', $this->config->item('company_name'), $row['subject']);
     $row['content'] = str_replace('{code}', $gc_data['code'], $row['content']);
     $row['content'] = str_replace('{amount}', format_currency($gc_data['beginning_amount']), $row['content']);
     $row['content'] = str_replace('{from}', $gc_data['from'], $row['content']);
     $row['content'] = str_replace('{personal_message}', nl2br($gc_data['personal_message']), $row['content']);
     $row['content'] = str_replace('{url}', $this->config->item('base_url'), $row['content']);
     $row['content'] = str_replace('{site_name}', $this->config->item('company_name'), $row['content']);
     $this->load->library('email');
     $config['mailtype'] = 'html';
     $this->email->initialize($config);
     $this->email->from($this->config->item('email'));
     $this->email->to($gc_data['to_email']);
     $this->email->subject($row['subject']);
     $this->email->message($row['content']);
     $this->email->send();
 }
开发者ID:RetinaInc,项目名称:GoCart-example,代码行数:22,代码来源:gift_card_model.php


示例9: foreach

	<tbody>
		<?php 
foreach ($payments as $payment) {
    ?>
		<tr>
			<td><?php 
    echo date_from_mysql($payment->payment_date);
    ?>
</td>
			<td><?php 
    echo $payment->invoice_number;
    ?>
</td>
			<td><?php 
    echo format_currency($payment->payment_amount);
    ?>
</td>
			<td><?php 
    echo $payment->payment_method_name;
    ?>
</td>
			<td><?php 
    echo $payment->payment_note;
    ?>
</td>
			<td>
				<div class="options btn-group">
					<a class="btn btn-small dropdown-toggle" data-toggle="dropdown" href="#"><i class="icon-cog"></i> <?php 
    echo lang('options');
    ?>
开发者ID:rumahkecil,项目名称:fusioninvoice-1,代码行数:30,代码来源:partial_payment_table.php


示例10: round

                    <div><h1><?php 
        //echo $product->name;
        ?>
G50-<?php 
        echo round($generator['generator_kVA']) . $generator['engine']->code . $generator['alternator']->code;
        ?>
AB</h1></div>
					<div>
						Standby Power: <?php 
        echo round($generator['generator_kVA']);
        ?>
 kVA
					</div>
					<div>
						Price: <?php 
        echo format_currency($generator['price']);
        ?>
					</div>
					<div>
						Days: <?php 
        echo $generator['days'];
        ?>
					</div>
					<!--
					<div>
						Engine Power: <?php 
        echo $generator['engine']->standby;
        ?>
 kWm, <?php 
        echo round($generator['engine']->standby / 0.8);
        ?>
开发者ID:lekhang,项目名称:gonline,代码行数:31,代码来源:homepage.php


示例11: format_currency

                                                  <span class="prod-price"><b><?php 
            echo format_currency($b->saleprice);
            echo empty($b->unit) ? '' : '/' . $b->unit;
            ?>
</b></span>
                                                  <a href="<?php 
            echo site_url(implode('/', $base_url) . '/' . $b->slug);
            ?>
" class="btn btn-nxled btn-sm pull-right" style="margin-top:7px;text-transform:uppercase;"> Add To Cart </a>
                                              </div>
                                          <?php 
        } else {
            ?>
                                              <div class="prod-priceCont clearfix" style="text-align:right;">
                                                <span class="prod-price"><b><?php 
            echo format_currency($b->price);
            echo empty($b->unit) ? '' : '/' . $b->unit;
            ?>
</b></span>
                                                <a href="<?php 
            echo site_url(implode('/', $base_url) . '/' . $b->slug);
            ?>
" class="btn btn-nxled btn-sm pull-right" style="margin-top:7px;text-transform:uppercase;"> Add To Cart </a>
                                              </div>
                                          <?php 
        }
        ?>
                                        </div><!-- prod-desc -->


                                    </div>
开发者ID:devarj,项目名称:design,代码行数:31,代码来源:category.php


示例12: __

        echo __('isLate');
        ?>
</label>
				<br/>
				<?php 
        echo "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;" . ($cir_hist->isLate($now) ? __('Yes') . " (" . $cir_hist->getLateDays($now) . " " . __('days') . ")" : __('No'));
        ?>
			</td>
			<td >
				<label><?php 
        echo __('Fine');
        ?>
</label>
				<br/>
				<?php 
        echo "&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Rp. " . format_currency($cir_hist->getFineAmount($now));
        echo input_hidden_tag('fine', $cir_hist->getFineAmount($now));
        ?>
			</td>
		</tr>
		<tr>
			<td >
				<label><?php 
        echo __('ColCondition');
        ?>
</label>
				<br/>
				<?php 
        echo object_select_tag($item, 'getColConditionId', array('related_class' => 'ColCondition', 'control_name' => 'col_condition_id'));
        ?>
			</td>
开发者ID:taryono,项目名称:school,代码行数:31,代码来源:orderSuccess.php


示例13: format_currency

    echo format_currency($quote_tax_rate->quote_tax_rate_amount);
    ?>
                                    </td>
                                </tr>
                            <?php 
}
?>

                            <tr class="amount-total border-top-n">
                                <td class="text-right color-d">
                                    <b><?php 
echo lang('total');
?>
:</b>
                                </td>
                                <td class="text-right color-d">
                                    <b><?php 
echo format_currency($quote->quote_total);
?>
</b>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
            </table>
            
        </div>
	</body>
</html>
开发者ID:quantumsized,项目名称:InvoicePlane,代码行数:30,代码来源:green.php


示例14: lang

echo lang('total');
?>
</td>
                <td class="amount"><b><?php 
echo format_currency($invoice->invoice_total);
?>
</b></td>
            </tr>
            <tr>
                <td><?php 
echo lang('paid');
?>
</td>
                <td class="amount"><b><?php 
echo format_currency($invoice->invoice_paid);
?>
</b></td>
            </tr>
            <tr>
                <td><b><?php 
echo lang('balance');
?>
</b></td>
                <td class="amount"><b><?php 
echo format_currency($invoice->invoice_balance);
?>
</b></td>
            </tr>
        </table>
    </div>
</div>
开发者ID:quantumsized,项目名称:InvoicePlane,代码行数:31,代码来源:partial_item_table.php


示例15: format_currency

">
                <p class="marginTop15">
                    <?php 
    echo $gen['result']['alternator_manufacturer'];
    ?>
<br>
                    <?php 
    echo $gen['result']['alt']->name;
    ?>
                </p>
            </div>
            <div class="resultado5 <?php 
    echo $line2;
    ?>
"><p class="marginTop20"><?php 
    echo format_currency($gen['result']['generators']['price']);
    ?>
</p></div>
            <div class="resultado6 <?php 
    echo $line2;
    ?>
">
                <p class="marginTop20"><?php 
    echo $gen['result']['generators']['days'];
    ?>
</p>
            </div>
            <div class="resultado7 <?php 
    echo $line2;
    ?>
">
开发者ID:lekhangyahoo,项目名称:gonline,代码行数:31,代码来源:gen_compare.php


示例16: _get_shipping_methods

 private function _get_shipping_methods()
 {
     $shipping_methods = array();
     /* do we need shipping? */
     if (config_item('require_shipping')) {
         /* do the cart contents require shipping? */
         if ($this->jcart->requires_shipping()) {
             /* ok so lets grab some shipping methods. If none exists, then we know that shipping isn't going to happen! */
             foreach ($this->Settings_model->get_settings('shipping_modules') as $shipping_method => $order) {
                 $this->load->add_package_path(APPPATH . 'packages/shipping/' . $shipping_method . '/');
                 /* eventually, we will sort by order, but I'm not concerned with that at the moment */
                 $this->load->library($shipping_method);
                 $shipping_methods = array_merge($shipping_methods, $this->{$shipping_method}->rates());
             }
             /*  Free shipping coupon applied ? */
             if ($this->jcart->is_free_shipping()) {
                 /*  add free shipping as an option, but leave other options in case they want to upgrade */
                 $shipping_methods[lang('free_shipping_basic')] = "0.00";
             }
             /*  format the values for currency display */
             foreach ($shipping_methods as &$method) {
                 /*  convert numeric values into an array containing numeric & formatted values */
                 $method = array('num' => $method, 'str' => format_currency($method));
             }
         }
     }
     if (!empty($shipping_methods)) {
         /* everything says that shipping is required! */
         return $shipping_methods;
     } else {
         return false;
     }
 }
开发者ID:nagsamayam,项目名称:jcom,代码行数:33,代码来源:Checkout.php


示例17: format_currency

                    ?>
</span>
		
		<?php 
                } else {
                    ?>
			<span class="price_reg"> <?php 
                    echo format_currency($product->price);
                    ?>
</span>
		<?php 
                }
            } else {
                ?>
			<span class="price_reg"> <?php 
                echo format_currency($product->price);
                ?>
</span>
		<?php 
            }
            ?>
	</div>
		<?php 
            if ((bool) $product->track_stock && $product->quantity < 1) {
                ?>
			<div class="stock_msg"><?php 
                echo lang('out_of_stock');
                ?>
</div>
		<?php 
            }
开发者ID:jonyhandoko,项目名称:khayana,代码行数:31,代码来源:new.php


示例18: DateToIndo

    ?>
","<?php 
    echo $cir_history->getMember() ? $cir_history->getMember()->getName() ? $cir_history->getMember()->getName() : '-' : '-';
    ?>
","<?php 
    echo $cir_history->getColItem() ? $cir_history->getColItem()->toString() : '-';
    ?>
","<?php 
    echo $cir_history->getColItem() ? $cir_history->getColItem()->getCatalog() ? $cir_history->getColItem()->getCatalog()->getTitle() : '-' : '-';
    ?>
","<?php 
    echo $cir_history->getOrderDate() ? DateToIndo($cir_history->getOrderDate('Y/m/d')) : '-';
    ?>
","<?php 
    echo $cir_history->getDueDate() ? DateToIndo($cir_history->getDueDate('Y/m/d')) : '-';
    ?>
","<?php 
    echo $cir_history->getReturnDate('U') > 0 ? DateToIndo($cir_history->getReturnDate('Y/m/d')) : '-';
    ?>
","<?php 
    echo $cir_history->getOrderLength($now);
    ?>
","<?php 
    echo format_currency($cir_history->getFine());
    ?>
","<?php 
    echo format_currency($cir_history->getMiscFine());
    ?>
"
<?php 
}
开发者ID:taryono,项目名称:school,代码行数:31,代码来源:listFineAsCSVSuccess.php


示例19: if

         <?php }; ?>
         </span>
         </td>
         <td>
         <span class="<?php if ($invoice->is_overdue) { ?>font-overdue<?php } ?>">
             <?php echo date_from_mysql($invoice->invoice_date_due); ?>
         </span>
         </td>
         <td>
             <?php echo anchor('invoices/view/' . $invoice->invoice_id, $invoice->invoice_number); ?>
         </td>
         <td>
             <?php echo anchor('clients/view/' . $invoice->client_id, $invoice->client_name); ?>
         </td>
         <td class="amount">
             <?php echo format_currency($invoice->invoice_balance * $invoice->invoice_sign); ?>
         </td>
         <td style="text-align: center;">
             <a href="<?php echo site_url('invoices/generate_pdf/' . $invoice->invoice_id); ?>"
                title="<?php echo lang('download_pdf'); ?>" target="_blank">
                 <i class="fa fa-print"></i>
             </a>
         </td>
     </tr>
 <?php } ?>
 <tr>
     <td colspan="6" class="text-right small">
         <?php echo anchor('invoices/status/all', lang('view_all')); ?>
     </td>
 </tr>
 </tbody>
开发者ID:n0rp3d,项目名称:invoice,代码行数:31,代码来源:index.php


示例20: process_payment_return

    function process_payment_return()
    {
        global $label;
        if ($_REQUEST['order_id'] != '' && $_REQUEST['nhezk5'] != '') {
            //print_r($_SESSION);
            if ($_SESSION['MDS_ID'] == '') {
                echo "Error: You must be logged in to view this page";
            } else {
                //require ("../users/header.php");
                ?>
			<div style='background-color: #ffffff; border-color:#C0C0C0; border-style:solid;padding:10px'>
		<p align="center"><center>
				<?php 
                $sql = "SELECT * from orders where order_id='" . $_REQUEST['order_id'] . "' and user_id='" . $_SESSION['MDS_ID'] . "'";
                $result = mysql_query($sql) or die(mysql_error() . $sql);
                $order_row = mysql_fetch_array($result);
                $check_amount = convert_to_currency($order_row['price'], $order_row['currency'], CHECK_CURRENCY);
                $check_amount = format_currency($check_amount, CHECK_CURRENCY, true);
                $label['payment_check_heading'] = str_replace("%INVOICE_AMOUNT%", $check_amount, $label['payment_check_heading']);
                //$label['payment_check_note'] = str_replace ("%CONTACT_EMAIL%", SITE_CONTACT_EMAIL, $label['payment_check_note']);
                //$label['payment_check_note'] = str_replace ("%INVOICE_CODE%", $_REQUEST['order_id'], $label['payment_check_note']);
                if (get_default_currency() != CHECK_CURRENCY) {
                    echo convert_to_default_currency_formatted($order_row[currency], $order_row['price']) . " = " . $check_amount;
                    echo "<br>";
                }
                ?>
				
				<table width="70%"><tr><td>
				<b><?php 
                echo $label['payment_check_heading'];
                ?>
</b><br>
				<?php 
                if (CHECK_NAME != '') {
                    ?>
				<b><?php 
                    echo $label['payment_check_payable'];
                    ?>
</b><pre><?php 
                    echo CHECK_PAYABLE;
                    ?>
</pre><br>
				<?php 
                }
                ?>
				<?php 
                if (CHECK_ADDRESS != '') {
                    ?>
				<b><?php 
                    echo $label['payment_check_address'];
                    ?>
</b><pre><?php 
                    echo CHECK_ADDRESS;
                    ?>
</pre><br>
				<?php 
                }
                ?>
				<?php 
                /*if ( CHECK_ACCOUNT_NAME != '') { ?>
                		<b><?php echo $label['payment_check_currency'];?></b><pre><?php echo CHECK_CURRENCY; ?></pre><br>
                		<?php } */
                ?>
				
					</td></tr>
					</table>
					
					</p>
					</center>
					
					</div>
					<?php 
            }
        }
    }
开发者ID:mix376,项目名称:MillionDollarScript,代码行数:75,代码来源:checkorder.php



注:本文中的format_currency函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP format_date函数代码示例发布时间:2022-05-15
下一篇:
PHP format_comment函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap