There are 3 main blocks/components of a viable XML File:
- Custom Forms
The upload process works in succession, i.e categories get imported first, followed by custom forms and custom form fields, and lastly, reports.
Guidelines and How to Upload XML
- The file to be uploaded must NOT be empty/must be a VALID xml file.Check to see if your XML file is valid.
- At least one of the blocks mentioned above MUST exist for the import to be successful
- Pre existing categories i.e those that exist on the deployment and are also listed in the XML file will not be imported/modified
- Category titles and descriptions MUST be provided
- For category translation import:-
- Localization abbreviations MUST be provided in the 'locale' attribute
- Category translation titles MUST be provided
Custom Forms import
- Pre existing forms will not be imported
- Form titles MUST be provided
- Pre existing custom form fields will not be imported
- For custom form fields
- Field name and type MUST be provided
- The only allowable field types are 1,2,3,4,5,6,7 . Any other value outside of that will cause the custom form field import to fail
- Field choices MUST be provided for radio button, checkbox and dropdown fields i.e field type 5, 6 and 7
- If field options('datatype' or/and 'hidden') are provided
- The only allowable datatype options are email, phonenumber, numeric and text
- If report id provided already exists, that entry will be ignored/won't be imported
- Report title and date MUST be provided
- Report date must be in the following format : yyyy-mm-dd hh:mm:ss
- If form_name provided is tied to a form that does not exist on the deployment, reports will be tagged to the default form
- If no latitude/longitude values are provided, the location will be geocoded.
- When importing custom form field responses for a specific report:-
- If field provided does not exist on the form the report is tied to, the response will NOT be imported
- For radio button, checkbox and drop down fields, the field responses MUST match the options tied to them.
- Checkbox responses should separated by a comma e.g if your selected choice of fruits is apples,mangoes and grapes, your entry for this should be "apples,mangoes,grapes"
- Date field values should be in the following format: mm/dd/yyyy e.g 3rd October 2012 = 10/03/2012
- When importing personal information
- At least one of the following values must be provided: First name, Last name or Email
- Email must be in the correct format
The following is a sample XML file viable for upload onto a deployment.