Hi all, I'm trying to create a JSON generator where you plug in numbers, and it creates a correctly formatted configuration.
I've created an input form which asks for a few variables, and then a submit button.
However, I don't want a database, I just want to enforce the form, and once the required fields are completed, the button click would create this JSON and clear the fields.
Input form:
- Security Key: _______
- Merchant ID: ___________
- Business Name: _________
JSON:
{
"security_key": "{{ form.data.securitykey }}",
"acquirerMerchantID": "{{ form.data.mid }}",
"merchantCountryCode": "500",
"merchantCurrencyCode": "500",
"merchantName": "{{ form.data.dba }}",
}
How do I do this on button select? As mentioned, I don't want to store this info into a database, the goal is simply to generate a read only JSON configuration so that users can quickly input this info and copy it.