form-synergy / custom-module
This template will install create a single module, this example will include all options and features. Great example.
dev-master
2019-04-07 11:30 UTC
Requires
- php: >=7.0
- form-synergy/php-api: >=1
Replaces
- form-synergy/custom-module: dev-master
This package is auto-updated.
Last update: 2022-01-07 18:02:18 UTC
README
This template will install create a single module, this example will include all options and features. Great example.
Install using composer
composer require form-synergy/custom-module
Include the library
require '/vendor/autoload.php';
Enable session management
\FormSynergy\Session::enable();
Import the Form Synergy class
use \FormSynergy\Fs as FS;
You will need to retrieve your credentials in the Form Synergy console.
Console Access: https://formsynergy.com/console/
- $profileid = '';
- $apikey = '';
- $apisecret = '';
If you are a reseller
- $resellerid = '';
Configuration
FS::Config([ 'version' => 'v1', 'protocol' => 'https', 'endpoint' => 'api.formsynergy.com', 'apikey' => $apikey, 'secretkey' => $secretkey, //'resellerid' => $resellerid, If you are a reseller 'max_auth_count' => 15, ]);
local storage
Enable local storage to store downloads and responses.
FS::Storage( '/', 'local-storage' );
Load account
Load and start managing an account.
$api = FS::Api()->Load($profileid);
Run script
update the empty values with the appropriate information.
\FormSynergy\Custom_Module::Run([ 'siteid' => '', 'modid' => '', /* * To experience module connections, * Please visit the playground page: https://formsynergy.com/playground/ * * NOTE: We are connecting this module * by providing the module id of the * next module to display. * */ 'onsubmit' => '' ])