• France
status page
Demo shops
assistance
FAQContact support
Search
Categories
Tags
Europe (English)
France
Spain
Europe (English)
India
Homepage
Use cases
Create a payment
Create an installment payment
Create a multi-card (split) payment
Create a payment by Alias (Token)
Create a payment link
Create a recurring payment
Manage subscriptions
Manage your transactions (refund, cancel...)
Analyze your reports
API docs
Embedded Form
REST API
Hosted payment
Mobile payment
File exchange
SDD mandates by REST API
Snippets
Payment methods
Plugins
Marketplace
Guides
Merchant Back Office
Back Office Expert
Functional guides

Managing shop settings via a configuration file

Using a configuration file allows to avoid including hard-coded values in the code.

The configuration files may contain:

  • the payment page URL,
  • the test and production keys,
  • the shop ID,
  • etc.

These files allow to sort the data to be saved.

The program that generates the payment form interrogates the configuration file to know the value of a parameter.

It is the merchant's responsibility to do anything in his or her power to limit the access to the configuration file (.htaccess file, rewrite the URL, etc.).

Example of "conf.txt" configuration file:
vads_site_id = 11111111
TEST_key = 2222222222222222
PROD_key = 3333333333333333
vads_ctx_mode = TEST
Example of a call to configuration file in the payment form:
$conf_txt = parse_ini_file("conf.txt");
if ($conf_txt['vads_ctx_mode'] == "TEST") $conf_txt['key'] = $conf_txt['TEST_key'];
if ($conf_txt['vads_ctx_mode'] == "PRODUCTION") $conf_txt['key'] = $conf_txt['PROD_key'];
Jobs
Legal
GDPR
25.18-1.11