Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Update instructions when the reverse proxy is an entry point
Excerpt

Define the required options in WEBSPELLCHECKER_CONFIG. It can be added to any location on a web page before or after the wscbundle.js script. However, if you add wscbundle.js asynchronously, this CONFIG must be added before the script.

  • Enable autoSearch functionality using the autoSearch parameter.
  • Specify serviceProtocolserviceHostservicePort and servicePath to access the service.
Info

In case of the direct connection to WebSpellChecker AppServer (AppServer is an entry point), you need to configure the SSL connection. Follow the steps described on the Enabling SSL connection with AppServer page (if you missed that step during the installation).

Code Block
languagejs
themeEmacs
<script>
	window.WEBSPELLCHECKER_CONFIG = {
		autoSearch: true,
		lang: 'en_US', // set the default language
        serviceProtocol: 'https',
        serviceHost: 'your_host_name',
        servicePort: '2880443', //2880
 is the default port that AppServer listens to. This is the entry point for the service. 
        servicePath: '/'servicePath: 'virtual_directory/api' // by default the virtual_directory is wscservice
   };
</script>
Note

If you are not able to use a custom port (e.g. 2880) to access the service and deployed the Server to use the FastCGI protocol (via the using the older version of the deployment where SSRV.CGI component), you need to use the different values to access the service properly. Now the entry point for the service requests will be the SSRV.CGI component is an entry point, please refer to the sample below.

Code Block
languagejs
themeEmacs
<script>
	window.WEBSPELLCHECKER_CONFIG = {
		autoSearch: true,
		lang: 'en_USauto', // set the default language
        serviceProtocol: 'http(s)https',
        serviceHost: 'your_host_name',
        servicePort: '443', // this is the port of your web server or Java application server
        servicePath: ''virtual_directory/script/ssrv.cgi''
   };
</script>

You also have an option to load your CONFIG option on your web page from the file. Just create a *.js file (e.g. wscbundle_config.js) with CONFIG. This is an example of the wscbundle_config.js file.

Code Block
languagejs
titlewscbundle_config.js
window.WEBSPELLCHECKER_CONFIG = {
	autoSearch: true,
	...
};

Here is an example of the script that you need to add on your web page with the path to wscbundle_config.js.

Code Block
languagejs
themeEmacs
<script type="text/javascript" src="[path_to_config]/wscbundle_config.js"></script>