Changing JSP files to select a preferred currency

You can allow customers to select a preferred currency from a list of supported currencies.


  1. Determine the store pages, and their associated JSP files, for which you want to create a list of currencies.
  2. For every page that a list is to display, open the JSP file of that page.
  3. To add a preferred currency list at the store level, use the following query as an example. This query gets a list of currencies from which customers can choose their preferred currency.
    <%@ page import="*" %>
    <%@ page import="*" %>
    <%@ page import="*" %>
    <%@ page import="*" %><%
        CommandContext commandContext = (CommandContext)
        StoreAccessBean storeAB = commandContext.getStore();
        CurrencyManager cm = CurrencyManager.getInstance();
        String[] supportedCurrencies =
    After the customer has chosen a currency, you can set it by invoking the SetCurrencyPreference command.