当前位置: 首页>>代码示例>>PHP>>正文


PHP CurrencyFormat函数代码示例

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


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

示例1: get_ib_items_list

 private static function get_ib_items_list($arFilter, $arSelectFields, $with_prices = false)
 {
     if (!CModule::IncludeModule("iblock")) {
         return false;
     }
     $arItems = array();
     $res = CIBlockElement::GetList(array("SORT" => "ASC", "NAME" => "ASC"), $arFilter, false, false, $arSelectFields);
     while ($item = $res->GetNext()) {
         if ($with_prices) {
             $item["PRICE"] = CCatalogProduct::GetOptimalPrice($item["ID"], self::DEFAULT_PRICE_ID, isset($GLOBALS['USER']) && $GLOBALS['USER'] ? $GLOBALS['USER']->GetUserGroupArray() : 0);
             if (isset($item["PRICE"]["RESULT_PRICE"]) && $item["PRICE"]["RESULT_PRICE"]) {
                 $item["PRICE_VALUE"] = $item["PRICE"]["RESULT_PRICE"]["BASE_PRICE"];
                 $item["PRICE_STR_VALUE"] = CurrencyFormat($item["PRICE"]["RESULT_PRICE"]["BASE_PRICE"], $item["PRICE"]["RESULT_PRICE"]["CURRENCY"]);
             } else {
                 $item["PRICE_VALUE"] = 0;
                 $item["PRICE_STR_VALUE"] = "";
             }
         }
         $arItems[$item["ID"]] = $item;
     }
     return $arItems;
 }
开发者ID:romlg,项目名称:bitrixcode,代码行数:22,代码来源:DrclinicsHelper.php

示例2: array

                     $price_orig_val = $arPrices["MATRIX"][$prid][0]["DISCOUNT_PRICE"];
                 }
                 if ($arResult["SEARCH"][$i]["MIN_PRICE"]["DISCOUNT_PRICE"] > $price_orig_val) {
                     $arResult["SEARCH"][$i]["MIN_PRICE"] = $arPrices["MATRIX"][$prid][0];
                 }
             } else {
                 $arResult["SEARCH"][$i]["MIN_PRICE"] = $arPrices["MATRIX"][$prid][0];
             }
         } else {
             $arResult["SEARCH"][$i]["MIN_PRICE"] = $arPrices["MATRIX"][1][0];
         }
     }
     if (isset($arResult["SEARCH"][$i]["MIN_PRICE"])) {
         $arResult["SEARCH"][$i]["PRICES"] = array();
         $arResult["SEARCH"][$i]["PRICES"]["PRICE"] = CurrencyFormat($arResult["SEARCH"][$i]["MIN_PRICE"]["PRICE"], $arParams["CURRENCY"]);
         $arResult["SEARCH"][$i]["PRICES"]["DISCOUNT_PRICE"] = CurrencyFormat($arResult["SEARCH"][$i]["MIN_PRICE"]["DISCOUNT_PRICE"], $arParams["CURRENCY"]);
     }
 }
 /* price end */
 /* preview start */
 if (CModule::IncludeModule('iblock')) {
     $ar_res = CIBlockElement::GetByID($arItem["ITEM_ID"])->GetNextElement();
     if ($ar_res) {
         $field = $ar_res->GetFields();
         $props = $ar_res->GetProperties();
         if ($field['PREVIEW_PICTURE']) {
             $arResult["SEARCH"][$i]["PREVIEW_PICTURE"] = CFile::GetPath($field['PREVIEW_PICTURE']);
         }
         $arResult["SEARCH"][$i]["FOR_ORDER"] = $props['FOR_ORDER'];
         if (!is_array($arResult["SEARCH"][$i]["PRICES"]) && is_array($props['PRICE_BASE'])) {
             $arResult["SEARCH"][$i]["PRICES"] = array();
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:31,代码来源:result_modifier.php

示例3: FormatBasketPriceChanged

 public static function FormatBasketPriceChanged($arData)
 {
     $info = GetMessage("SOC_BASKET_PRICE_CHANGED_INFO");
     foreach ($arData as $param => $value) {
         $info = str_replace("#" . $param . "#", $value, $info);
     }
     $info = str_replace("#AMOUNT#", CurrencyFormat($arData["PRICE"], $arData["CURRENCY"]), $info);
     return array("NAME" => GetMessage("SOC_BASKET_PRICE_CHANGED"), "INFO" => $info);
 }
开发者ID:rasuldev,项目名称:torino,代码行数:9,代码来源:order_change.php

示例4: SaleFormatCurrency

            $result['DELIVERY_DISCOUNT_PRICE'] = $orderDeliveryPriceData['DELIVERY_PRICE'];
            $result["DELIVERY_DISCOUNT_PRICE_FORMATED"] = SaleFormatCurrency($orderDeliveryPriceData['DELIVERY_PRICE'], $arParams["CURRENCY"]);
        }
    }
    $result["TEXT"] = $calcResult->isSuccess() ? $calcResult->getDescription() : implode("<br>\n", $calcResult->getErrorMessages());
    if ($calcResult->isNextStep()) {
        $result["RESULT"] = "NEXT_STEP";
    }
    if ($calcResult->isSuccess() && strlen($calcResult->getDescription()) > 0) {
        $result["RESULT"] = "NOTE";
    }
    if (intval($calcResult->getPacksCount()) > 0) {
        $result["PACKS_COUNT"] = $calcResult->getPacksCount();
    }
    if ($calcResult->isSuccess() && CModule::IncludeModule('currency')) {
        $result["VALUE_FORMATTED"] = CurrencyFormat($calcResult->getPrice(), $arParams["CURRENCY"]);
    } elseif ($calcResult->isNextStep() && strlen($calcResult->getTmpData()) > 0) {
        $result["TEMP"] = CUtil::JSEscape($calcResult->getTmpData());
    }
    $arResult["RESULT"] = $result;
} else {
    $arParams["STEP"] = 0;
    $arResult["B_ADMIN"] = defined("ADMIN_SECTION") && ADMIN_SECTION === true ? "Y" : "N";
    if ($arResult["B_ADMIN"] != "Y") {
        $folderPath = "";
        IncludeAJAX();
        if ($this->InitComponentTemplate()) {
            $template = $this->GetTemplate();
            if ($template) {
                $folderPath = $template->GetFolder();
            }
开发者ID:akniyev,项目名称:itprom_dobrohost,代码行数:31,代码来源:component.php

示例5: array

        if ($uptime[0] > 0 && $uptime[1] > 0) {
            $uptimeRate = $uptime[0] / $uptime[1];
        }
    }
    if ($uptimeRate < 1 && $saleIncluded) {
        $base = CCurrency::GetBaseCurrency();
        $r = CSaleOrder::GetList(array(), array(">=DATE_INSERT" => ConvertTimeStamp(time() - $monitoring->getInterval() * 24 * 3400, "SHORT")), array("LID", "CURRENCY", "SUM" => "PRICE"));
        while ($a = $r->fetch()) {
            $sum += CCurrencyRates::ConvertCurrency($a["PRICE"], $a["CURRENCY"], $base);
        }
        $sum *= 1 - $uptimeRate;
        if ($sum <= 0.0) {
            $sumHtml = number_format((1 - $uptimeRate) * 100, 2, '.', ' ') . "%";
            $alertIntervalText = $intervalLang["uptime"][$monitoring->getInterval()];
        } else {
            $sumHtml = CurrencyFormat($sum, $base);
            $alertIntervalText = $intervalLang["sale"][$monitoring->getInterval()];
        }
    } elseif ($testCount === 1 && HasMessage("GD_BITRIXCLOUD_MONITOR_" . strtoupper($testAlert->getName()))) {
        $uptimeRate = 1;
        $resultText = FormatDate("ddiff", time(), $testAlert->getResult());
        $sumHtml = GetMessage("GD_BITRIXCLOUD_MONITOR_" . strtoupper($testAlert->getName()), array("#DOMAIN#" => $converter->Decode($testDomain), "#DAYS#" => $resultText));
    } elseif ($uptimeRate < 1) {
        $sumHtml = number_format((1 - $uptimeRate) * 100, 2, '.', ' ') . "%";
        $alertIntervalText = $intervalLang["uptime"][$monitoring->getInterval()];
    } else {
        $sumHtml = GetMessage("GD_BITRIXCLOUD_MONITOR_PROBLEMS", array("#COUNT#" => $testCount));
    }
}
?>
<div class="bx-gadgets-content-layout-inspector">
开发者ID:webgksupport,项目名称:alpina,代码行数:31,代码来源:index.php

示例6: array

                 }
             }
         }
     }
 }
 $arCurrencyList = array();
 $arDBCurrencies = array();
 $dbCurrencyList = CCurrency::GetList($b = "", $o = "");
 while ($arCurrency = $dbCurrencyList->Fetch()) {
     $arDBCurrencies[$arCurrency["CURRENCY"]] = $arCurrency["AMOUNT_CNT"];
 }
 foreach ($arParams["arrCURRENCY_FROM"] as &$strCurrencyCode) {
     if (array_key_exists($strCurrencyCode, $arDBCurrencies)) {
         $arCurrencyList[] = $strCurrencyCode;
         $rate = CCurrencyRates::ConvertCurrency($arDBCurrencies[$strCurrencyCode], $strCurrencyCode, $arParams["CURRENCY_BASE"], $arParams["RATE_DAY"]);
         $arResult["CURRENCY"][] = array('FROM' => CurrencyFormat($arDBCurrencies[$strCurrencyCode], $strCurrencyCode), 'BASE' => CurrencyFormat($rate, $arParams["CURRENCY_BASE"]));
     }
 }
 if (isset($strCurrencyCode)) {
     unset($strCurrencyCode);
 }
 if (!empty($arCurrencyList)) {
     if (defined("BX_COMP_MANAGED_CACHE")) {
         $arCurrencyList[] = $arParams["CURRENCY_BASE"];
         $arCurrencyList = array_unique($arCurrencyList);
         $CACHE_MANAGER->StartTagCache($this->GetCachePath());
         foreach ($arCurrencyList as &$strOneCurrency) {
             $CACHE_MANAGER->RegisterTag("currency_id_" . $strOneCurrency);
         }
         if (isset($strOneCurrency)) {
             unset($strOneCurrency);
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:component.php

示例7: FormatInvoicePriceChanged

 public static function FormatInvoicePriceChanged($arData)
 {
     $info = GetMessage("CRM_INVOICE_EVENT_INFO_PRICE_CHANGED", array("#AMOUNT#" => CurrencyFormat($arData["PRICE"], $arData["CURRENCY"])));
     return array("INFO" => $info);
 }
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:5,代码来源:crm_invoice_event.php

示例8: getBasketTotalPrice

 public static function getBasketTotalPrice($currency)
 {
     \CModule::IncludeModule('sale');
     if (!($userFilter = static::getBasketUserFilter())) {
         return array();
     }
     $rsBasket = \CSaleBasket::GetList(array(), $userFilter + array("CAN_BUY" => "Y", "DELAY" => "N", "SUBSCRIBE" => "N"), false, false, array("QUANTITY", "PRICE", "CURRENCY", "DISCOUNT_PRICE", "WEIGHT", "VAT_RATE", "ID", "SET_PARENT_ID", "PRODUCT_ID", "CATALOG_XML_ID", "PRODUCT_XML_ID", "PRODUCT_PROVIDER_CLASS", "TYPE"));
     $arBasketItems = array();
     while ($arItem = $rsBasket->Fetch()) {
         if (\CSaleBasketHelper::isSetItem($arItem)) {
             continue;
         }
         $arBasketItems[] = $arItem;
     }
     $totalPrice = 0;
     if ($arBasketItems) {
         $arOrder = static::calculateBasket($arBasketItems);
         $totalPrice = $arOrder['ORDER_PRICE'];
     }
     return array('NUM_PRODUCTS' => count($arBasketItems), 'TOTAL_PRICE' => CurrencyFormat($totalPrice, $currency));
 }
开发者ID:firestorm23,项目名称:bxhelper,代码行数:21,代码来源:BXHelper.php

示例9: GetLiveFeedData


//.........这里部分代码省略.........
         $strSiteCurrency = CCurrency::GetBaseCurrency();
     }
     if ($saleRight != "W") {
         $arFilterPerms = array("STATUS_PERMS_GROUP_ID" => $GLOBALS["USER"]->GetUserGroupArray(), ">=STATUS_PERMS_PERM_VIEW" => "Y");
     } else {
         $arFilterPerms = array();
     }
     $d = date("w");
     if ($d < 1) {
         $d = -6;
     } elseif ($d > 1) {
         $d = $d - 1;
     } else {
         $d = 0;
     }
     $BeforeLastWeek_minDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-" . (14 + $d)), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $BeforeLastWeek_maxDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-" . (7 + $d), "SS" => -1), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $LastWeek_minDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-" . (7 + $d)), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $LastWeek_maxDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-" . $d, "SS" => -1), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $ThisWeek_minDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-" . $d), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $ThisWeek_maxDate = ConvertTimeStamp(mktime(0, 0, 0, date("n"), date("j") + 1, date("Y")), "FULL");
     $BeforeYesterday_minDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-2"), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $BeforeYesterday_maxDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-1", "SS" => -1), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $Yesterday_minDate = ConvertTimeStamp(AddToTimeStamp(array("DD" => "-1"), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $Yesterday_maxDate = ConvertTimeStamp(AddToTimeStamp(array("SS" => -1), mktime(0, 0, 0, date("n"), date("j"), date("Y"))), "FULL");
     $Today_minDate = ConvertTimeStamp(mktime(0, 0, 0, date("n"), date("j"), date("Y")), "FULL");
     $Today_maxDate = ConvertTimeStamp(mktime(0, 0, 0, date("n"), date("j") + 1, date("Y")), "FULL");
     $arDatePeriods = array("BEFORE_LAST_WEEK" => array("MIN_DATE" => $BeforeLastWeek_minDate, "MAX_DATE" => $BeforeLastWeek_maxDate), "LAST_WEEK" => array("MIN_DATE" => $LastWeek_minDate, "MAX_DATE" => $LastWeek_maxDate), "THIS_WEEK" => array("MIN_DATE" => $ThisWeek_minDate, "MAX_DATE" => $ThisWeek_maxDate), "BEFORE_YESTERDAY" => array("MIN_DATE" => $BeforeYesterday_minDate, "MAX_DATE" => $BeforeYesterday_maxDate), "YESTERDAY" => array("MIN_DATE" => $Yesterday_minDate, "MAX_DATE" => $Yesterday_maxDate), "TODAY" => array("MIN_DATE" => $Today_minDate, "MAX_DATE" => $Today_maxDate));
     $arStatus1 = array("CREATED" => array("NAME" => GetMessage("BX_WS_SALE_STATUS_1_CREATED"), "DB_FIELD" => "DATE"), "PAID" => array("NAME" => GetMessage("BX_WS_SALE_STATUS_1_PAID"), "DB_FIELD" => "DATE_PAYED"), "CANCELED" => array("NAME" => GetMessage("BX_WS_SALE_STATUS_1_CANCELED"), "DB_FIELD" => "DATE_UPDATE", "Y_FIELD" => "CANCELED"), "ALLOW_DELIVERY" => array("NAME" => GetMessage("BX_WS_SALE_STATUS_1_ALLOW_DELIVERY"), "DB_FIELD" => "DATE_UPDATE", "Y_FIELD" => "ALLOW_DELIVERY"));
     foreach ($arDatePeriods as $key => $arPeriod) {
         foreach ($arStatus1 as $status_code => $arStatus) {
             $arOrderStats[$key][$status_code] = 0;
             $arOrderStats[$key]["PRICE_" . $status_code] = 0;
         }
         foreach ($arStatus1 as $status_code => $arStatus) {
             if (!is_array($arGadgetParams["ORDERS_STATUS_1"]) || in_array($status_code, $arGadgetParams["ORDERS_STATUS_1"])) {
                 if (array_key_exists("Y_FIELD", $arStatus) && strlen($arStatus["Y_FIELD"]) > 0) {
                     $arFilterYField = array($arStatus["Y_FIELD"] => "Y");
                 } else {
                     $arFilterYField = array();
                 }
                 $arFilter = array_merge(array($arStatus["DB_FIELD"] . "_FROM" => $arPeriod["MIN_DATE"], $arStatus["DB_FIELD"] . "_TO" => $arPeriod["MAX_DATE"]), $arFilterLID, $arFilterPerms, $arFilterYField);
                 $dbOrder = CSaleOrder::GetList(array(), $arFilter, array("SUM" => "PRICE", "COUNT" => "ID"));
                 if ($arOrder = $dbOrder->Fetch()) {
                     $arOrderStats[$key][$status_code] = $arOrder["ID"];
                     $arOrderStats[$key]["PRICE_" . $status_code] = $arOrder["PRICE"];
                 }
             }
         }
     }
     $strSaleStat = '<table border="0">';
     $strSaleStat .= '<tr><td>&nbsp;</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td><b>' . $arStatus["NAME"] . '</b></td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_TODAY") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["TODAY"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_YESTERDAY") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["YESTERDAY"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_BEFOREYESTERDAY") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["BEFORE_YESTERDAY"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_THISWEEK") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["THIS_WEEK"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_LASTWEEK") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["LAST_WEEK"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '<tr><td>' . GetMessage("BX_WS_SALE_BEFORELASTWEEK") . '</td>';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStat .= '<td align="center">' . intval($arOrderStats["BEFORE_LAST_WEEK"][$status_code]) . '</td>';
     }
     $strSaleStat .= '</tr>';
     $strSaleStat .= '</table>';
     $strSaleStatText = '';
     foreach ($arStatus1 as $status_code => $arStatus) {
         $strSaleStatText .= '#BR#' . $arStatus["NAME"] . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_TODAY") . ' ' . intval($arOrderStats["TODAY"][$status_code]) . (intval($arOrderStats["TODAY"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["TODAY"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_YESTERDAY") . ' ' . intval($arOrderStats["YESTERDAY"][$status_code]) . (intval($arOrderStats["YESTERDAY"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["YESTERDAY"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_BEFOREYESTERDAY") . ' ' . intval($arOrderStats["BEFORE_YESTERDAY"][$status_code]) . (intval($arOrderStats["BEFORE_YESTERDAY"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["BEFORE_YESTERDAY"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_THISWEEK") . ' ' . intval($arOrderStats["THIS_WEEK"][$status_code]) . (intval($arOrderStats["THIS_WEEK"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["THIS_WEEK"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_LASTWEEK") . ' ' . intval($arOrderStats["LAST_WEEK"][$status_code]) . (intval($arOrderStats["LAST_WEEK"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["LAST_WEEK"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
         $strSaleStatText .= GetMessage("BX_WS_SALE_BEFORELASTWEEK") . ' ' . intval($arOrderStats["BEFORE_LAST_WEEK"][$status_code]) . (intval($arOrderStats["BEFORE_LAST_WEEK"][$status_code]) > 0 ? ' (' . CurrencyFormat($arOrderStats["BEFORE_LAST_WEEK"]["PRICE_" . $status_code], $strSiteCurrency) . ')' : '') . '#BR#';
     }
     $arResult = array("TITLE" => htmlspecialchars(GetMessage("BX_WS_SALE_LF_TITLE")), "MESSAGE" => htmlspecialchars($strSaleStat), "TEXT_MESSAGE" => htmlspecialchars($strSaleStatText), "URL" => htmlspecialchars($protocol . "://" . $server_name . "/bitrix/admin/sale_stat.php?lang=" . $lang));
     return $arResult;
 }
开发者ID:Satariall,项目名称:izurit,代码行数:101,代码来源:component.php

示例10: foreach

            ?>
</th>
								</tr><?php 
            foreach ($arResult["VIEWED"] as $val) {
                ?>
<tr>
										<td><?php 
                echo htmlspecialcharsbx($val["NAME"]);
                ?>
</td>
										<td align="right"><?php 
                echo IntVal($val["ID"]);
                ?>
</td>
										<td align="right" nowrap><?php 
                echo DoubleVal($val["PRICE"]) > 0 ? CurrencyFormat(DoubleVal($val["PRICE"]), $val["CURRENCY"]) : "";
                ?>
</td>
									</tr><?php 
            }
            ?>
</tbody>
						</table><?php 
        } else {
            ?>
<div align="center" class="bx-gadgets-content-padding-rl bx-gadgets-content-padding-t"><?php 
            echo GetMessage("GD_PRD_NO_DATA");
            ?>
</div><?php 
        }
    }
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:index.php

示例11: array

			$arCurrencyList = array();

			$arDBCurrencies = array();
			$dbCurrencyList = CCurrency::GetList(($b = ""), ($o = ""));
			while ($arCurrency = $dbCurrencyList->Fetch())
				$arDBCurrencies[$arCurrency["CURRENCY"]] = $arCurrency["AMOUNT_CNT"];

			foreach ($arParams["arrCURRENCY_FROM"] as &$strCurrencyCode)
			{
				if (array_key_exists($strCurrencyCode, $arDBCurrencies))
				{
					$arCurrencyList[] = $strCurrencyCode;
					$rate = CCurrencyRates::ConvertCurrency($arDBCurrencies[$strCurrencyCode], $strCurrencyCode, $arParams["CURRENCY_BASE"], $arParams["RATE_DAY"]);
					$arResult["CURRENCY"][] = array(
						'FROM' => CurrencyFormat($arDBCurrencies[$strCurrencyCode], $strCurrencyCode),
						'BASE' => CurrencyFormat($rate, $arParams["CURRENCY_BASE"]),
					);
				}
			}
			if (isset($strCurrencyCode))
				unset($strCurrencyCode);

			if (!empty($arCurrencyList))
			{
				if (defined("BX_COMP_MANAGED_CACHE"))
				{
					$arCurrencyList[] = $arParams["CURRENCY_BASE"];
					$arCurrencyList = array_unique($arCurrencyList);
					$CACHE_MANAGER->StartTagCache($this->GetCachePath());
					foreach ($arCurrencyList as &$strOneCurrency)
					{
开发者ID:ASDAFF,项目名称:1C_Bitrix_info_site,代码行数:31,代码来源:component.php

示例12: strlen

$signature = CSalePaySystemAction::GetParamValue("SIGN");
$url = "https://liqpay.com/?do=clickNbuy";
$resultUrl = CSalePaySystemAction::GetParamValue("PATH_TO_RESULT_URL");
$serverUrl = CSalePaySystemAction::GetParamValue("PATH_TO_SERVER_URL");
$orderID = strlen(CSalePaySystemAction::GetParamValue("ORDER_ID")) > 0 ? CSalePaySystemAction::GetParamValue("ORDER_ID") : $GLOBALS["SALE_INPUT_PARAMS"]["ORDER"]["ID"];
$currency = strlen(CSalePaySystemAction::GetParamValue("CURRENCY")) > 0 ? CSalePaySystemAction::GetParamValue("CURRENCY") : $GLOBALS["SALE_INPUT_PARAMS"]["ORDER"]["CURRENCY"];
$phone = CSalePaySystemAction::GetParamValue("PHONE");
$pay_method = CSalePaySystemAction::GetParamValue("PAY_METHOD");
echo GetMessage("PAYMENT_DESCRIPTION_PS");
?>
 <b>LiqPAY.com</b>.<br /><br />
<?php 
echo GetMessage("PAYMENT_DESCRIPTION_SUM");
?>
: <b><?php 
echo CurrencyFormat(CSalePaySystemAction::GetParamValue("SHOULD_PAY"), $currency);
?>
</b><br /><br />
<?php 
if ($currency == "RUB") {
    $currency = "RUR";
}
$xml = "<request>\n\t\t<version>1.2</version>\n\t\t<result_url>" . $resultUrl . "</result_url>\n\t\t<server_url>" . $serverUrl . "</server_url>\n\t\t<merchant_id>" . $merchant_id . "</merchant_id>\n\t\t<order_id>ORDER_" . $orderID . "</order_id>\n\t\t<payment_id>PAYMENT_" . CSalePaySystemAction::GetParamValue("ORDER_PAYMENT_ID") . "</payment_id>\n\t\t<amount>" . CSalePaySystemAction::GetParamValue("SHOULD_PAY") . "</amount>\n\t\t<currency>" . $currency . "</currency>\n\t\t<description>Payment for Order " . $orderID . "</description>\n\t\t<default_phone>" . $phone . "</default_phone>\n\t\t<pay_way>" . $pay_method . "</pay_way>\n\t\t</request>";
$xml_encoded = base64_encode($xml);
$lqsignature = base64_encode(sha1($signature . $xml . $signature, 1));
?>
<form action="<?php 
echo $url;
?>
" method="post">
	<input type="hidden" name="operation_xml" value="<?php 
开发者ID:DarneoStudio,项目名称:bitrix,代码行数:31,代码来源:payment.php

示例13: foreach

<?
$arResult["TOTAL"] = 0;
$arResult["TOTALPRICE"] = 0;
foreach($arResult["ITEMS"] as $arItem) {
	$arResult["TOTAL"] += $arItem["QUANTITY"];
	$arResult["TOTALPRICE"] += $arItem["PRICE"]*$arItem["QUANTITY"];
}
$arResult["TOTALPRICE_FORMATTED"] = CurrencyFormat($arResult["TOTALPRICE"],$arResult["ITEMS"][0]["CURRENCY"]);
?>
开发者ID:schiz,项目名称:purecountry,代码行数:9,代码来源:result_modifier.php

示例14: htmlspecialcharsex

        $row->AddInputField("CODE", false);
        $row->AddInputField("EXTERNAL_ID", false);
        $row->AddViewField("TAGS", htmlspecialcharsex($row->arRes["TAGS"]));
        $row->AddCalendarField("DATE_ACTIVE_FROM", false);
        $row->AddCalendarField("DATE_ACTIVE_TO", false);
        $row->AddViewField("WF_STATUS_ID", htmlspecialcharsex($arWFStatusAll[$row->arRes['WF_STATUS_ID']]));

        if ($bCatalog) {
            $row->AddInputField("CATALOG_QUANTITY", false);
            $row->AddSelectField("CATALOG_QUANTITY_TRACE", $arQuantityTrace, false);
            $row->AddInputField("CATALOG_WEIGHT", false);
            $row->AddCheckField("CATALOG_VAT_INCLUDED", false);
            if ($boolCatalogPurchasInfo) {
                if (0 < doubleval($row->arRes["CATALOG_PURCHASING_PRICE"])) {
                    if ($bCurrency) {
                        $price = CurrencyFormat($row->arRes["CATALOG_PURCHASING_PRICE"], $row->arRes["CATALOG_PURCHASING_CURRENCY"]);
                    } else {
                        $price = $row->arRes["CATALOG_PURCHASING_PRICE"] . " " . $row->arRes["CATALOG_PURCHASING_CURRENCY"];
                    }
                    $row->AddViewField("CATALOG_PURCHASING_PRICE", htmlspecialcharsEx($price));
                }
            }
            $row->AddInputField("CATALOG_MEASURE_RATIO", false);
        }
        if (array_key_exists("PREVIEW_PICTURE", $arSelectedFieldsMap)) {
            $row->AddViewFileField("PREVIEW_PICTURE", array(
                "IMAGE" => "Y",
                "PATH" => "Y",
                "FILE_SIZE" => "Y",
                "DIMENSIONS" => "Y",
                "IMAGE_POPUP" => "Y",
开发者ID:ASDAFF,项目名称:bitrix-modules-setprops,代码行数:31,代码来源:setprops.php

示例15: base64_encode

    $signature = base64_encode(sha1($private_key . $data . $private_key, 1));
}
if (!($action = CSalePaySystemAction::GetParamValue('ACTION'))) {
    $action = 'https://www.liqpay.com/api/checkout';
}
?>

<?php 
echo GetMessage('PAYMENT_DESCRIPTION_PS');
?>
 <b>www.liqpay.com</b>.<br /><br />
<?php 
echo GetMessage('PAYMENT_DESCRIPTION_SUM');
?>
: <b><?php 
echo CurrencyFormat($amount, $currency);
?>
</b><br /><br />

<form method="POST" action="<?php 
echo $action;
?>
" accept-charset="utf-8">
    <input type="hidden" name="signature" value="<?php 
echo $signature;
?>
" />
    <input type="hidden" name="data" value="<?php 
echo $data;
?>
" />
开发者ID:norayrx,项目名称:plugin-bitrix,代码行数:31,代码来源:payment.php


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