How to Localize Your Store
The following steps outline how to install RazorCart language packs to localize the cart in your desired language:
- Make sure you have RazorCart installed
- Login to your portal as Administrator and navigate to the DNN Admin menu – Languages option.
- Select the language you would like to use in your store from the drop down list. If the language for your specific locale is not listed in the dropdown list you will need to login as "Host" and add your desired language pack from DNN Host - Languages menu option. Once you have installed additional language packs within your portal those languages will be available from the dropdown list.
- Each RazorCart module has its own resx files located in the following folder.
- \DesktopModules\MVC\RazorCart\[ModuleName]\App_LocalResources
Note: You can translate the resx files to your language using the Google language translator or using your favorite editor open the resx files listed in the folders above and translate into your desired language and “save as” when complete. Translated text should only be added to the “Value” column of the resource file. Make sure that you do not over write the existing resx files and “save as” a different file name. When saving your resx files make sure you use the naming conventions described in section below titled “Resource File (Resx) Naming Conventions”.
Resource File (Resx) Naming Conventions
After you have translated the label values in the resx files you will need to save the files in the proper naming convention in order for the language localization to work correctly.
For example, if you have translated the Checkout.resx resource file in the \desktopmodules\MVC\RazorCart\Checkout\App_LocalResources folder you will need to save it according to the following file naming convention that applies to your locale/language.
Checkout.resx - This is the default local resource file (the fallback resource file) if no language match is found.
Checkout.es.resx - This is the resource file for Spanish.
Checkout.es-mx.resx - This is the resource file for Spanish (Mexico) specifically
Checkout.fr-fr.resx - This is the resource file for French.
Checkout.de-de.resx - This is the resource file for German.
The base name of the file matches the module name, followed by a language and culture name, and ending with the extension .resx. For a complete list of culture names, see the following link https://msdn.microsoft.com/en-us/library/bb975829.aspx
You are welcome to contribute your translated resx files back to the RazorCart community and they will be included in the next build of the cart so you can take advantage of future upgrades. You can email a zip file of your translated resx files to our Support Department.
Localizing Product Data