CurrencySelect
The CurrencySelect server control lets a customer select the monetary type he will use to make purchases. When a currency is selected, eCommerce server controls use it for that order. If the customer closes the browser, the currency needs to be selected again the next time the site is visited.
For a currency to appear in the CurrencySelect server control, enable it in the Workarea > Settings > Commerce > Currencies screen. See also: Configuring Currencies.
Inserting the CurrencySelect server control onto a page
Prerequisite
You must have installed the server controls. See Installing server controls into Visual Studio Toolbox.
- In Visual Studio, choose View > Toolbox.
- Click the Ektron server control tab to display the server controls.
- Drag the CurrencySelect server control and drop it into the desired location on the page.
NOTE: You also can place the cursor on the page where you want the server control, then double click the server control that you want.
<CMS:CurrencySelect ID="CurrencySelect1" runat="server" />
- Click on
CurrencySelect
in the code to display and modify the control’s properties using the Properties window of Visual Studio. The page is updated as you modify the property values.
CurrencySelect properties
The following are Ektron-specific server controla server control uses API language to interact with the CMS and Framework UI to display the output. A server control can be dragged and dropped onto a Web form and then modified. properties. For information about native .NET properties such as font, height, width and border style, use Visual Studio® help.
- CustomXml (Code-behind Only) (String)
Lets you inject custom XML into the generated XML before being processed by the XSLTExtensible Stylesheet Language Transformations. Enter a string of XML that you want to make available to the XSLT as follows:
<root><customXml>custom-xml-inserted-here</customXml></root>
See also: Displaying custom XML in Ektron’s server controls.
- DisplayXslt (String)
If desired, enter a relative or absolute path to an Xslt that determines the display of the page. By default, the control uses
siteroot\Workarea\Xslt\Commerce\CurrencySelect.xsl.
WARNING! Files stored in the
siteroot\Workarea
folder are overwritten (or deleted) when you upgrade Ektron. To avoid problems, copy the default file to a folder outside thesiteroot\workarea
folder then edit it. If there is no default file, create the file outside thesiteroot\workarea
folder. Next, in this property, enter the path to that file relative to the site root folder. - DoInitFill (Boolean)
By default, Fill occurs during the Page_Init event. Set to false if you want to postpone the fill-action until later. In this case, Fill is automatically called during the Page Render event. You might do this if you need to set or change a property on the control in code-behind and have it render with your changes shown.
- Hide (Boolean)
Hides or displays the output of the control in design time and run time.
- True. Hide the control output.
- False. Display the control output.
- Language (Integer)
Set a language for viewing content; shows results in design-time (in Visual Studio) and at run-time (in a browser).
- Stylesheet (String)
Specify the path to a style sheet for use with this server control. Leave blank to use the default style sheet. To use a custom style sheet, place it in a folder outside the
siteroot\workarea
folder then edit it. Next, in this property, enter the path to the custom style sheet relative to the site root folder. - SuppressWrapperTags (Boolean)
Suppresses the output of the span/div tags around the control.
- True. Suppress wrap tags.
- False (default). Allow wrap tags.