Page 1 of 1

Load texts from external JSON files

Posted: Fri Feb 06, 2026 10:46 am
by miguelss
Hi Pablo / everyone,

I’m building a website with WYSIWYG Web Builder and I’d like to implement multilingual support (for example: Spanish/English) in a maintainable way.

My goal is:
* Design pages normally in WWB.
* Avoid hardcoding visible text directly in each element.
* Load texts from external JSON files (one file per language, e.g. es.json, en.json).
* Switch language with a button/dropdown.
* Keep selected language in localStorage (or similar), so it persists between visits.[/list]

I’m considering using data-i18n attributes in elements and a JavaScript function that fetches the selected JSON and replaces element text at runtime.
I know there are extensions that can help with multilingual websites, but I’d specifically like to understand and use this JSON-based approach.

Could you confirm if this is a recommended method in WWB?

If yes, what is the cleanest way to integrate it in WWB projects (layout grids, forms, menus, extensions)?
Also, are there known limitations when using this method?

Thanks in advance!

Re: Load texts from external JSON files

Posted: Fri Feb 06, 2026 12:26 pm
by Pablo
I have no experience with this approach so I cannot tell if this will work, but you can try.
Unfortunately I cannot help with the implementation of this because for me it would also take several horus to figure this out.

Re: Load texts from external JSON files

Posted: Fri Feb 06, 2026 1:06 pm
by miguelss
Thank you for your reply, Pablo.
I think it's possible.

How?
If the website is already finished, we need to extract the unique IDs of the text, labels, etc. and publish them in a JSON file (e.g. de.json for the German language).
Then I need to create a selector with /index.html?lang=de

and include a script in the end of the body for that purpose.
I will come back with an example!

Cheers,
M.