[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
[phpBB Debug] PHP Warning: in file [ROOT]/includes/crs/crs_misc_functions.php on line 37: mime_content_type(): Empty filename or path
Zen Cart 源代码 currencies.php

Zen Cart 源代码 currencies.php




下载文件

文件名: currencies.php
文件类型: PHP文件
文件大小: 20.13 KiB
MD5: 4fd6dbf2e629e76405f1e1535d41a04a

currencies.php - 关闭高亮
  1. <?php
  2. /**
  3.  * @package admin
  4.  * @copyright Copyright 2003-2014 Zen Cart Development Team
  5.  * @copyright Portions Copyright 2003 osCommerce
  6.  * @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
  7.  * @version GIT: $Id: Author: DrByte  Jun 30 2014 Modified in v1.5.4 $
  8.  */
  9.  
  10.   require('includes/application_top.php');
  11.  
  12.   require(DIR_WS_CLASSES . 'currencies.php');
  13.   $currencies = new currencies();
  14.  
  15.   $action = (isset($_GET['action']) ? $_GET['action'] : '');
  16.  
  17.   if (zen_not_null($action)) {
  18.     switch ($action) {
  19.       case 'insert':
  20.       case 'save':
  21.         if ($_POST['title'] == '' || $_POST['code'] == '' ) {
  22.           $_GET['action']= '';
  23.           $messageStack->add_session(ERROR_INVALID_CURRENCY_ENTRY, 'error');
  24.           zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page']));
  25.           break;
  26.         }
  27.  
  28.         if (isset($_GET['cID'])) $currency_id = zen_db_prepare_input($_GET['cID']);
  29.         $title = zen_db_prepare_input($_POST['title']);
  30.         $code = strtoupper(zen_db_prepare_input($_POST['code']));
  31.         $symbol_left = zen_db_prepare_input($_POST['symbol_left']);
  32.         $symbol_right = zen_db_prepare_input($_POST['symbol_right']);
  33.         $decimal_point = zen_db_prepare_input($_POST['decimal_point']);
  34.         $thousands_point = zen_db_prepare_input($_POST['thousands_point']);
  35.         $decimal_places = zen_db_prepare_input((int)$_POST['decimal_places']);
  36.         $value = zen_db_prepare_input((float)$_POST['value']);
  37.  
  38.         // special handling for currencies which don't support decimal places
  39.         if ($decimal_point == '0' || in_array($code, array('JPY', 'HUF', 'TWD'))) {
  40.           $value = (int)$value;
  41.           $decimal_places = 0;
  42.         }
  43.  
  44.         $sql_data_array = array('title' => $title,
  45.                                 'code' => $code,
  46.                                 'symbol_left' => $symbol_left,
  47.                                 'symbol_right' => $symbol_right,
  48.                                 'decimal_point' => $decimal_point,
  49.                                 'thousands_point' => $thousands_point,
  50.                                 'decimal_places' => $decimal_places,
  51.                                 'value' => $value);
  52.  
  53.         if ($action == 'insert') {
  54.           zen_db_perform(TABLE_CURRENCIES, $sql_data_array);
  55.           $currency_id = zen_db_insert_id();
  56.         } elseif ($action == 'save') {
  57.           zen_db_perform(TABLE_CURRENCIES, $sql_data_array, 'update', "currencies_id = '" . (int)$currency_id . "'");
  58.         }
  59.         zen_record_admin_activity('Currency code ' . $code . ' added/updated.', 'info');
  60.  
  61.         if (isset($_POST['default']) && ($_POST['default'] == 'on')) {
  62.           $db->Execute("update " . TABLE_CONFIGURATION . "
  63.                        set configuration_value = '" . zen_db_input($code) . "'
  64.                        where configuration_key = 'DEFAULT_CURRENCY'");
  65.           zen_record_admin_activity('Default currency code changed to ' . $code, 'info');
  66.         }
  67.  
  68.         zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $currency_id));
  69.         break;
  70.       case 'deleteconfirm':
  71.         // demo active test
  72.         if (zen_admin_demo()) {
  73.           $_GET['action']= '';
  74.           $messageStack->add_session(ERROR_ADMIN_DEMO, 'caution');
  75.           zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page']));
  76.         }
  77.         $currencies_id = zen_db_prepare_input($_POST['cID']);
  78.  
  79.         $currency = $db->Execute("select currencies_id
  80.                                  from " . TABLE_CURRENCIES . "
  81.                                  where code = '" . zen_db_input(DEFAULT_CURRENCY) . "'");
  82.         if ($currency->fields['currencies_id'] == $currencies_id) {
  83.           $db->Execute("update " . TABLE_CONFIGURATION . "
  84.                        set configuration_value = ''
  85.                        where configuration_key = 'DEFAULT_CURRENCY'");
  86.         }
  87.         $db->Execute("delete from " . TABLE_CURRENCIES . "
  88.                      where currencies_id = '" . (int)$currencies_id . "'");
  89.  
  90.         zen_record_admin_activity('Deleted currency with currencies_id of ' . $currencies_id, 'notice');
  91.         zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page']));
  92.         break;
  93.       case 'update_currencies':
  94.         $server_used = CURRENCY_SERVER_PRIMARY;
  95.         zen_set_time_limit(600);
  96.         $currency = $db->Execute("select currencies_id, code, title, decimal_places from " . TABLE_CURRENCIES);
  97.         while (!$currency->EOF) {
  98.           $quote_function = 'quote_' . CURRENCY_SERVER_PRIMARY . '_currency';
  99.           $rate = $quote_function($currency->fields['code']);
  100.  
  101.           if (empty($rate) && (zen_not_null(CURRENCY_SERVER_BACKUP))) {
  102.             // failed to get currency quote from primary server - attempting to use backup server instead
  103.             $messageStack->add_session(sprintf(WARNING_PRIMARY_SERVER_FAILED, CURRENCY_SERVER_PRIMARY, $currency->fields['title'], $currency->fields['code']), 'warning');
  104.             $quote_function = 'quote_' . CURRENCY_SERVER_BACKUP . '_currency';
  105.             $rate = $quote_function($currency->fields['code']);
  106.             $server_used = CURRENCY_SERVER_BACKUP;
  107.           }
  108.  
  109.           /* Add currency uplift */
  110.           if ($rate != 1 && defined('CURRENCY_UPLIFT_RATIO') && (int)CURRENCY_UPLIFT_RATIO != 0) {
  111.             $rate = (string)((float)$rate * (float)CURRENCY_UPLIFT_RATIO);
  112.           }
  113.  
  114.           // special handling for currencies which don't support decimal places
  115.           if ($currency->fields['decimal_places'] == '0') {
  116.             $rate = (int)$rate;
  117.           }
  118.  
  119.           if (zen_not_null($rate) && $rate > 0) {
  120.             $db->Execute("update " . TABLE_CURRENCIES . "
  121.                          set value = '" . $rate . "', last_updated = now()
  122.                          where currencies_id = '" . (int)$currency->fields['currencies_id'] . "'");
  123.             $messageStack->add_session(sprintf(TEXT_INFO_CURRENCY_UPDATED, $currency->fields['title'], $currency->fields['code'], $server_used), 'success');
  124.           } else {
  125.             $messageStack->add_session(sprintf(ERROR_CURRENCY_INVALID, $currency->fields['title'], $currency->fields['code'], $server_used), 'error');
  126.           }
  127.           $currency->MoveNext();
  128.         }
  129.         zen_record_admin_activity('Currency exchange rates updated via the Update button in the admin console.', 'info');
  130.         zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $_GET['cID']));
  131.         break;
  132.       case 'delete':
  133.         // demo active test
  134.         if (zen_admin_demo()) {
  135.           $_GET['action']= '';
  136.           $messageStack->add_session(ERROR_ADMIN_DEMO, 'caution');
  137.           zen_redirect(zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $_GET['cID']));
  138.         }
  139.         $currencies_id = zen_db_prepare_input($_GET['cID']);
  140.  
  141.         $currency = $db->Execute("select code
  142.                                  from " . TABLE_CURRENCIES . "
  143.                                  where currencies_id = '" . (int)$currencies_id . "'");
  144.  
  145.         $remove_currency = true;
  146.         if ($currency->fields['code'] == DEFAULT_CURRENCY) {
  147.           $remove_currency = false;
  148.           $messageStack->add(ERROR_REMOVE_DEFAULT_CURRENCY, 'error');
  149.         }
  150.         break;
  151.     }
  152.   }
  153. ?>
  154. <!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">
  155. <html <?php echo HTML_PARAMS; ?>>
  156. <head>
  157. <meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">
  158. <title><?php echo TITLE; ?></title>
  159. <link rel="stylesheet" type="text/css" href="includes/stylesheet.css">
  160. <link rel="stylesheet" type="text/css" href="includes/cssjsmenuhover.css" media="all" id="hoverJS">
  161. <script language="javascript" src="includes/menu.js"></script>
  162. <script language="javascript" src="includes/general.js"></script>
  163. <script type="text/javascript">
  164.   <!--
  165.   function init()
  166.   {
  167.     cssjsmenu('navbar');
  168.     if (document.getElementById)
  169.     {
  170.       var kill = document.getElementById('hoverJS');
  171.       kill.disabled = true;
  172.     }
  173.   }
  174.   // -->
  175. </script>
  176. </head>
  177. <body onLoad="init()">
  178. <!-- header //-->
  179. <?php require(DIR_WS_INCLUDES . 'header.php'); ?>
  180. <!-- header_eof //-->
  181.  
  182. <!-- body //-->
  183. <table border="0" width="100%" cellspacing="2" cellpadding="2">
  184.   <tr>
  185. <!-- body_text //-->
  186.     <td width="100%" valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="2">
  187.       <tr>
  188.         <td><table border="0" width="100%" cellspacing="0" cellpadding="0">
  189.           <tr>
  190.             <td class="pageHeading"><?php echo HEADING_TITLE; ?></td>
  191.             <td class="pageHeading" align="right"><?php echo zen_draw_separator('pixel_trans.gif', HEADING_IMAGE_WIDTH, HEADING_IMAGE_HEIGHT); ?></td>
  192.           </tr>
  193.         </table></td>
  194.       </tr>
  195.       <tr>
  196.         <td><table border="0" width="100%" cellspacing="0" cellpadding="0">
  197.           <tr>
  198.             <td valign="top"><table border="0" width="100%" cellspacing="0" cellpadding="2">
  199.               <tr class="dataTableHeadingRow">
  200.                 <td class="dataTableHeadingContent"><?php echo TABLE_HEADING_CURRENCY_NAME; ?></td>
  201.                 <td class="dataTableHeadingContent"><?php echo TABLE_HEADING_CURRENCY_CODES; ?></td>
  202.                 <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_CURRENCY_VALUE; ?></td>
  203.                 <td class="dataTableHeadingContent" align="right"><?php echo TABLE_HEADING_ACTION; ?>&nbsp;</td>
  204.               </tr>
  205. <?php
  206.   $currency_query_raw = "select currencies_id, title, code, symbol_left, symbol_right, decimal_point, thousands_point, decimal_places, last_updated, value from " . TABLE_CURRENCIES . " order by title";
  207.   $currency_split = new splitPageResults($_GET['page'], MAX_DISPLAY_SEARCH_RESULTS, $currency_query_raw, $currency_query_numrows);
  208.   $currency = $db->Execute($currency_query_raw);
  209.   while (!$currency->EOF) {
  210.     if ((!isset($_GET['cID']) || (isset($_GET['cID']) && ($_GET['cID'] == $currency->fields['currencies_id']))) && !isset($cInfo) && (substr($action, 0, 3) != 'new')) {
  211.       $cInfo = new objectInfo($currency->fields);
  212.     }
  213.  
  214.     if (isset($cInfo) && is_object($cInfo) && ($currency->fields['currencies_id'] == $cInfo->currencies_id) ) {
  215.       echo '              <tr id="defaultSelected" class="dataTableRowSelected" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="document.location.href=\'' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=edit') . '\'">' . "\n";
  216.     } else {
  217.       echo '              <tr class="dataTableRow" onmouseover="rowOverEffect(this)" onmouseout="rowOutEffect(this)" onclick="document.location.href=\'' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $currency->fields['currencies_id']) . '\'">' . "\n";
  218.     }
  219.  
  220.     if (DEFAULT_CURRENCY == $currency->fields['code']) {
  221.       echo '                <td class="dataTableContent"><b>' . $currency->fields['title'] . ' (' . TEXT_DEFAULT . ')</b></td>' . "\n";
  222.     } else {
  223.       echo '                <td class="dataTableContent">' . $currency->fields['title'] . '</td>' . "\n";
  224.     }
  225. ?>
  226.                 <td class="dataTableContent"><?php echo $currency->fields['code']; ?></td>
  227.                 <td class="dataTableContent" align="right"><?php echo number_format($currency->fields['value'], 8); ?></td>
  228.                 <td class="dataTableContent" align="right"><?php if (isset($cInfo) && is_object($cInfo) && ($currency->fields['currencies_id'] == $cInfo->currencies_id) ) { echo zen_image(DIR_WS_IMAGES . 'icon_arrow_right.gif'); } else { echo '<a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $currency->fields['currencies_id']) . '">' . zen_image(DIR_WS_IMAGES . 'icon_info.gif', IMAGE_ICON_INFO) . '</a>'; } ?>&nbsp;</td>
  229.               </tr>
  230. <?php
  231.     $currency->MoveNext();
  232.   }
  233. ?>
  234.               <tr>
  235.                 <td colspan="4"><table border="0" width="100%" cellspacing="0" cellpadding="2">
  236.                   <tr>
  237.                     <td class="smallText" valign="top"><?php echo $currency_split->display_count($currency_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, $_GET['page'], TEXT_DISPLAY_NUMBER_OF_CURRENCIES); ?></td>
  238.                     <td class="smallText" align="right"><?php echo $currency_split->display_links($currency_query_numrows, MAX_DISPLAY_SEARCH_RESULTS, MAX_DISPLAY_PAGE_LINKS, $_GET['page']); ?></td>
  239.                   </tr>
  240. <?php
  241.   if (empty($action)) {
  242. ?>
  243.                   <tr>
  244.                     <td><?php if (CURRENCY_SERVER_PRIMARY) { echo '<a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=update_currencies') . '">' . zen_image_button('button_update_currencies.gif', IMAGE_UPDATE_CURRENCIES) . '</a>'; } ?></td>
  245.                     <td align="right"><?php echo '<a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=new') . '">' . zen_image_button('button_new_currency.gif', IMAGE_NEW_CURRENCY) . '</a>'; ?></td>
  246.                   </tr>
  247. <?php
  248.   }
  249. ?>
  250.                 </table></td>
  251.               </tr>
  252.             </table></td>
  253. <?php
  254.   $heading = array();
  255.   $contents = array();
  256.  
  257.   switch ($action) {
  258.     case 'new':
  259.       $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_NEW_CURRENCY . '</b>');
  260.  
  261.       $contents = array('form' => zen_draw_form('currencies', FILENAME_CURRENCIES, 'page=' . $_GET['page'] . (isset($cInfo) ? '&cID=' . $cInfo->currencies_id : '') . '&action=insert'));
  262.       $contents[] = array('text' => TEXT_INFO_INSERT_INTRO);
  263.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_TITLE . '<br>' . zen_draw_input_field('title'));
  264.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_CODE . '<br>' . zen_draw_input_field('code'));
  265.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_SYMBOL_LEFT . '<br>' . zen_draw_input_field('symbol_left'));
  266.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_SYMBOL_RIGHT . '<br>' . zen_draw_input_field('symbol_right'));
  267.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_DECIMAL_POINT . '<br>' . zen_draw_input_field('decimal_point'));
  268.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_THOUSANDS_POINT . '<br>' . zen_draw_input_field('thousands_point'));
  269.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_DECIMAL_PLACES . '<br>' . zen_draw_input_field('decimal_places'));
  270.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_VALUE . '<br>' . zen_draw_input_field('value'));
  271.       $contents[] = array('text' => '<br>' . zen_draw_checkbox_field('default') . ' ' . TEXT_INFO_SET_AS_DEFAULT);
  272.       $contents[] = array('align' => 'center', 'text' => '<br>' . zen_image_submit('button_insert.gif', IMAGE_INSERT) . ' <a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $_GET['cID']) . '">' . zen_image_button('button_cancel.gif', IMAGE_CANCEL) . '</a>');
  273.       break;
  274.     case 'edit':
  275.       $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_EDIT_CURRENCY . '</b>');
  276.  
  277.       $contents = array('form' => zen_draw_form('currencies', FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=save'));
  278.       $contents[] = array('text' => TEXT_INFO_EDIT_INTRO);
  279.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_TITLE . '<br>' . zen_draw_input_field('title', htmlspecialchars($cInfo->title, ENT_COMPAT, CHARSET, TRUE)));
  280.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_CODE . '<br>' . zen_draw_input_field('code', htmlspecialchars($cInfo->code, ENT_COMPAT, CHARSET, TRUE)));
  281.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_SYMBOL_LEFT . '<br>' . zen_draw_input_field('symbol_left', htmlspecialchars($cInfo->symbol_left, ENT_COMPAT, CHARSET, TRUE)));
  282.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_SYMBOL_RIGHT . '<br>' . zen_draw_input_field('symbol_right', htmlspecialchars($cInfo->symbol_right, ENT_COMPAT, CHARSET, TRUE)));
  283.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_DECIMAL_POINT . '<br>' . zen_draw_input_field('decimal_point', htmlspecialchars($cInfo->decimal_point, ENT_COMPAT, CHARSET, TRUE)));
  284.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_THOUSANDS_POINT . '<br>' . zen_draw_input_field('thousands_point', htmlspecialchars($cInfo->thousands_point, ENT_COMPAT, CHARSET, TRUE)));
  285.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_DECIMAL_PLACES . '<br>' . zen_draw_input_field('decimal_places', $cInfo->decimal_places));
  286.       $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_VALUE . '<br>' . zen_draw_input_field('value', $cInfo->value));
  287.       if (DEFAULT_CURRENCY != $cInfo->code) $contents[] = array('text' => '<br>' . zen_draw_checkbox_field('default') . ' ' . TEXT_INFO_SET_AS_DEFAULT);
  288.       $contents[] = array('align' => 'center', 'text' => '<br>' . zen_image_submit('button_update.gif', IMAGE_UPDATE) . ' <a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id) . '">' . zen_image_button('button_cancel.gif', IMAGE_CANCEL) . '</a>');
  289.       break;
  290.     case 'delete':
  291.       $heading[] = array('text' => '<b>' . TEXT_INFO_HEADING_DELETE_CURRENCY . '</b>');
  292.       $contents = array('form'=>zen_draw_form('delete', FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&action=deleteconfirm') . zen_draw_hidden_field('cID', $cInfo->currencies_id));
  293.       $contents[] = array('text' => TEXT_INFO_DELETE_INTRO);
  294.       $contents[] = array('text'=> (($remove_currency) ? zen_image_submit('button_delete.gif', IMAGE_DELETE) : '') . ' <a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $_GET['cID']) . '">' . zen_image_button('button_cancel.gif', IMAGE_CANCEL) . '</a>', 'align'=>'center');
  295.       $contents[] = array('text' => '<br><b>' . $cInfo->title . '</b>');
  296.       break;
  297.     default:
  298.       if (is_object($cInfo)) {
  299.         $heading[] = array('text' => '<b>' . $cInfo->title . '</b>');
  300.  
  301.         $contents[] = array('align' => 'center', 'text' => '<a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=edit') . '">' . zen_image_button('button_edit.gif', IMAGE_EDIT) . '</a> <a href="' . zen_href_link(FILENAME_CURRENCIES, 'page=' . $_GET['page'] . '&cID=' . $cInfo->currencies_id . '&action=delete') . '">' . zen_image_button('button_delete.gif', IMAGE_DELETE) . '</a>');
  302.         $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_TITLE . ' ' . $cInfo->title);
  303.         $contents[] = array('text' => TEXT_INFO_CURRENCY_CODE . ' ' . $cInfo->code);
  304.         $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_SYMBOL_LEFT . ' ' . $cInfo->symbol_left);
  305.         $contents[] = array('text' => TEXT_INFO_CURRENCY_SYMBOL_RIGHT . ' ' . $cInfo->symbol_right);
  306.         $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_DECIMAL_POINT . ' ' . $cInfo->decimal_point);
  307.         $contents[] = array('text' => TEXT_INFO_CURRENCY_THOUSANDS_POINT . ' ' . $cInfo->thousands_point);
  308.         $contents[] = array('text' => TEXT_INFO_CURRENCY_DECIMAL_PLACES . ' ' . $cInfo->decimal_places);
  309.         $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_LAST_UPDATED . ' ' . zen_date_short($cInfo->last_updated));
  310.         $contents[] = array('text' => TEXT_INFO_CURRENCY_VALUE . ' ' . number_format($cInfo->value, 8));
  311.         $contents[] = array('text' => '<br>' . TEXT_INFO_CURRENCY_EXAMPLE . '<br>' . $currencies->format('30', false, DEFAULT_CURRENCY) . ' = ' . $currencies->format('30', true, $cInfo->code));
  312.       }
  313.       break;
  314.   }
  315.  
  316.   if ( (zen_not_null($heading)) && (zen_not_null($contents)) ) {
  317.     echo '            <td width="25%" valign="top">' . "\n";
  318.  
  319.     $box = new box;
  320.     echo $box->infoBox($heading, $contents);
  321.  
  322.     echo '            </td>' . "\n";
  323.   }
  324. ?>
  325.           </tr>
  326.         </table></td>
  327.       </tr>
  328.     </table></td>
  329. <!-- body_text_eof //-->
  330.   </tr>
  331. </table>
  332. <!-- body_eof //-->
  333.  
  334. <!-- footer //-->
  335. <?php require(DIR_WS_INCLUDES . 'footer.php'); ?>
  336. <!-- footer_eof //-->
  337. <br>
  338. </body>
  339. </html>
  340. <?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>
  341.  


cron