Zen Cart Logo
Forums / Currencies & Sales Taxes, VAT, GST, etc. / Currency drop down menu on product page?

Currency drop down menu on product page?

Views: 1,575

Results 1 to 2 of 2
18 Apr 2011, 12:09 PM
#1
thannaree avatar

thannaree

Zen Follower

Join Date:
Dec 2010
Location:
Thailand
Posts:
304
Plugin Contributions:
1

Currency drop down menu on product page?

I've got the currencies drop-down menu located in the header, which works perfectly fine but it seems that many customers couldn't see it. So, I've been trying to place it also somewhere next to the price on the product page (with the code indicated below) but when dropping it down to a different currency, that just takes me to the check-out page.

Could someone help me a bit?
Thanks!

<!-- Currencies -->

<?=zen_draw_form('currencies', zen_href_link(basename(ereg_replace('.php','', $PHP_SELF)), '', $request_type, false), 'get')?>

<?

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

      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($_GET);
      while (list($key, $value) = each($_GET)) {
        if ( ($key != 'currency') && ($key != zen_session_name()) && ($key != 'x') && ($key != 'y') ) {
          $hidden_get_variables .= zen_draw_hidden_field($key, $value);
        }
      }
    }

?>

        <?=zen_draw_pull_down_menu('currency', $currencies_array, $_SESSION['currency'], 'class="header1_sel" onchange="this.form.submit();"') . $hidden_get_variables . zen_hide_session_id()?>
</form>
<!-- End Currencies -->
22 Apr 2011, 2:52 AM
#2
thannaree avatar

thannaree

Zen Follower

Join Date:
Dec 2010
Location:
Thailand
Posts:
304
Plugin Contributions:
1

Re: Currency drop down menu on product page?

If this is something too complicated to do, perhaps I should hire a developer for that job. What do you recommend?