Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add examples of countries and regions via JSON #282

Merged
merged 5 commits into from
Jun 13, 2024
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions docs/contacts/custom_fields.rst
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,28 @@ If you configure this option, the new Custom Field becomes visible in the list o
This configuration helps prevent **http** request timeouts because it handles the long-running SQL query to create the new table column as a background task.

To mitigate the table lock issue, run the command only once daily when you know that most of your audience is offline. With less traffic going into Mautic, the chances of encountering a problem are lower.

Locally defined countries and regions
*************************************

Since Mautic 5.1 it's possible to define custom countries and regions via locally hosted JSON files. This is useful when you have a specific set of countries or regions that you want to use in your Mautic instance. You can define these in a file called ``countries.json`` or ``regions.json`` located in your defined ``upload_dir``. Example code snippets are below:
RCheesley marked this conversation as resolved.
Show resolved Hide resolved

.. code:: json

[
RCheesley marked this conversation as resolved.
Show resolved Hide resolved
"Middle Earth",
"Fillory"
]

.. code:: json

{
RCheesley marked this conversation as resolved.
Show resolved Hide resolved
"Middle Earth": [
"The Shire",
"Mordor"
],
"Fillory": [
"Castle Whitespire",
"Ember's Tomb"
]
}
Loading