<?php

/*

  $Id: currencies.php,v 1.16 2003/02/12 20:27:31 hpdl Exp $



  osCommerce, Open Source E-Commerce Solutions

  http://www.oscommerce.com



  Copyright (c) 2003 osCommerce



  Released under the GNU General Public License

*/



  if (isset($currencies) && is_object($currencies)) {

?>

<!-- currencies //-->

          <tr>

<td>

<TABLE cellSpacing=0 cellPadding=0 width="100%">

                    <TBODY>

                    <TR>

                      <TD colSpan=3 width="179"><IMG alt=Categories

                       src="images/box title/best.gif"></TD></TR>



                      <TD vAlign="top" width="212" align="center">

                        <TABLE cellSpacing=0 cellPadding=0 width="100%" border=0>

                          <TBODY>

                          <TR>

                            <TD>

                              <TABLE cellSpacing=0

                              cellPadding=0 width="100%" border=0>

                                <TBODY>



                                <TR>



                      <TD>

<?php





    reset($currencies->currencies);

    $currencies_array = array();

    while (list($key, $value) = each($currencies->currencies)) {

      $currencies_array[] = array('id' => $key, 'text' => $value['title']);

    }



    $hidden_get_variables = '';

    reset($HTTP_GET_VARS);

    while (list($key, $value) = each($HTTP_GET_VARS)) {

      if ( ($key != 'currency') && ($key != tep_session_name()) && ($key != 'x') && ($key != 'y') ) {

        $hidden_get_variables .= tep_draw_hidden_field($key, $value);

      }

    }



    $info_box_contents = array();

    $info_box_contents[] = array('form' => tep_draw_form('currencies', tep_href_link(basename($PHP_SELF), '', $request_type, false), 'get'),

                                 'align' => 'center',

                                 'text' => tep_draw_pull_down_menu('currency', $currencies_array, $currency, 'onChange="this.form.submit();" style="width: 100%"') . $hidden_get_variables . tep_hide_session_id());



    new infoBox($info_box_contents);

?>

          </TD>

                    </TR>

                                </TBODY></TABLE></TD></TR></TBODY></TABLE></TD>



      <TD

                      width="7" height="1"><IMG

                        height=1

                        src="images/pixel_trans.gif"

                        width=5></TD>

    </TR>

                    <TR>

                      <TD colSpan=3 valign="top"></TD></TR></TBODY></TABLE>

       </tr>

<!-- currencies_eof //-->

<?php

  }

?>