Formatting Strings

This section of the FreeMarker template is responsible for processing and formatting item dimensions (length, width, height) to three decimal places. The input string: 5″ x 4″ x 2″ Assign Original String: The dimensions of the item are stored in the dimensions variable. <#assign dimensions = itemLineDetails.dimensions /> Remove Double Quotes: To facilitate easier processing,… Continue reading Formatting Strings

Reserved Names in FreeMarker Template Language (FTL)

FreeMarker Template Language (FTL) is a powerful tool for creating dynamic web pages and emails, among other uses. However, like any programming or scripting language, it has certain reserved names that you need to be aware of. These names are keywords in FTL and cannot be used for top-level variables unless accessed using square-bracket syntax… Continue reading Reserved Names in FreeMarker Template Language (FTL)

Understanding Comparisons in FreeMarker Templates

When working with FreeMarker templates, you often need to compare values to determine equality or which value is greater. This guide will walk you through the basic comparison operations and how to use them effectively within your FreeMarker templates. The if Directive In FreeMarker, the if directive is used to evaluate conditions. The syntax for… Continue reading Understanding Comparisons in FreeMarker Templates

Points to Note While Removing ‘Free’ From Shipping Methods with Zero Rate

Removing the “Free!” text from the shipping method list displayed on the website on the checkout page using content management. We can only replace the text by blank space or any other alternative symbol or text. The Shipping methods with non-zero cost will be displayed in the UI, only zero-cost in shipping method the “Free!”… Continue reading Points to Note While Removing ‘Free’ From Shipping Methods with Zero Rate

FreeMarker Formatting Method

NetSuite formatting is lost when you customize NetSuite standard fields. If you print hard-coded values which came from a custom data source or were calculated from standard fields, the format will not be consistent with the format of standard record fields. When editing the template source code, the nsformat_() formatting method makes it possible to… Continue reading FreeMarker Formatting Method