SSP Applications (SuiteScript 1.0 Compared with SuiteScript 2.0)
You can write SSP applications in either SuiteScript 1.0 or 2.0, but you can't combine both versions in a single SSP application. Each SSP application can have scripts written in either SuiteScript 1.0 or 2.0. The SuiteScript version affects how SSP applications are created, installed, and deployed.
Enabling SuiteScript 2.0 doesn't affect how SuiteScript 1.0 SSP applications work.
Here are the main differences between SSP applications written in SuiteScript 1.0 and 2.0:
-
Different syntax is used in SuiteScript 2.0 and SuiteScript 1.0– SuiteScript 2.0 scripts in SSP applications must start with this declaration:
<%@ NApiVersion="2.x"%>
This declaration ensures that the script uses the latest minor version of SuiteScript 2.0. You don't need a declaration in SuiteScript 1.0 scripts. For more information and examples, see Sample SSP Application Code (SuiteScript 2.0).
-
Explicit deployment required for SuiteScript 2.0 SSP applications– to be accessible on a website or domain. Deploying to a website makes it available on all domains associated with the website. Deploying to a domain makes it available only there. For more information, see Deploy and Undeploy SSP Applications.
-
Single SuiteScript 2.0 SSP application permitted per path – if you have more than one with the same URL root, you can't deploy them to the same domain or website.
-
Touch points aren't supported for SuiteScript 2.0 SSP applications– instead they use a default SSP file as a single entry point.
Currently, there aren't any NetSuite SSP application with a default application file, but you can create and use your own.
You'll be able to select a default SSP file for a domain or website in a future release. In 2018.2, you can use SuiteScript 2.0 SSP applications for:
-
Backend processing, like logging.
-
Website services you can access with a direct link to the URL root where it's deployed.
For more information, see Select Default SSP File.
-