Friday, February 1, 2019

Dynamically Assign Data Center in PHP Toolkit 2012.2

For partners and developers using the 2012.2 PHP Toolkit who work on accounts that reside in both data centers, you can modify the toolkit's configuration files to allow assigning of data center dynamically.

1. Modify NSconfig.php:

//add the following lines

 $environmentstrng = $environment;
 $environmentstrng = "";

//modify $nshost

$nshost = "https://webservices." . $environmentstrng . "";

2. Modify NSPHPClient.php. Add global variable $environment in protected function __construct($wsdl=null, $options=array())

3. Dynamically assign value for $environment in your PHP code (either "" or "na1.")

No comments:

Post a Comment