Back to Website
Product Documentation Operations Portal CMS Configure CMS Custom Form Processing

Operations CMS - Custom Form Processing

  1. Example Custom Form

    Many websites have forms on their website, this is an example of a "Contact Us" form.

  2. Send Emails Based on Form Values

    It's also common to have more than one form on a website, such as this "Register" form. Using the "Custom Form Processing" functionality, each form on your website can be associated with a different email address, which will receive the submissions. For example, all submitted "Contact Us" forms can be delivered to one email address, and all "Register" forms can be sent to another email address.

  3. Click on "CMS"

    To configure this functionality, you will need to assign names to all of the forms on your website. In this example, we will use the "Contact Us" and "Register" forms. To begin, navigate to "CMS" in the Operations Portal.

  4. Click "Pages"

    Click on "Pages" to access a list of all your website pages.

  5. Search for the page name

    In the search bar at the top of the "Pages" screen, type the name of the page where the form is located. In this case, we will search "contact" to locate the "Contact Us" page.

  6. Click the "Edit" icon

    Click the "Edit" icon to open the page editor.

  7. Select the block

    Use your mouse to select the form fill's block.

  8. Click the "Block" tab

    Click the "Block" tab at the top of the settings panel.

  9. Give your block a name

    Give the form block a name by adding a keyword to the "Select name" text box. In this case, we will type "contact".

  10. Click "Save"

    Save the changes to the page by clicking the "Save" button.

  11. Search for the page name

    Head back to the "Pages" screen in the Operations Portal. You will now follow the same process for any other forms on your website. Use the search bar at the top of the screen to type in the name of the page where the form is located. In this case, we will use our second form for registrations.

  12. Click the "Edit" icon

    Click the "Edit" icon to open the page editor.

  13. Select the block

    Use your mouse to select the form fill's block.

  14. Click the "Block" tab

    Click the "Block" tab at the top of the settings panel.

  15. Give your block a name

    Give the form block a name by adding a keyword to the "Select name" text box. In this case, we will type "register".

  16. Click "Save"

    Save the changes to the page by clicking the "Save" button.

  17. Type "API Scripts"

    Head back to the Operations Portal and type "API Scripts" into the search bar at the top of the the navigation menu.

  18. Click "API Scripts"

    Click "API Scripts" to access the screen with all of your system's API scripts.

  19. Locate "processCustomerForm.js

    Locate the script titled "processCustomerForm.js".

  20. Click the "Details" icon

    Click the script's "Details" icon to access the script page.

  21. Locate the "toEmails" variable

    Find the "toEmails" variable in the script.

  22. Add code

    To signal to your system what form responses should be delivered to what email address, you will need to add the code displayed on the screen. Add this code directly after the "toEmails" variable.

  23. Add the name of your CMS block

    Add the name you gave your CMS block earlier. In this example, we named one of our form blocks, "register".

  24. Add an email address

    Replace this email address with the one you want to receive the submissions based on the form name you added in the last step.

  25. Add code

    To tie another form to a different email address, add the "else if" code to your script immediately below the code you previously added.

  26. Add the name of your CMS block

    Add the name you gave your CMS block earlier. In this example, we named our other form, "contact".

  27. Add an email address

    Replace this email address with an email address different from the one that was previously entered in the other line of code.

  28. Repeat code if needed

    You can repeat the "else if" code for as many forms as you have on your website.

  29. Click "Save"

    Save the changes to your script by clicking the "Save" button.

  30. Fill out a test form

    To test the new form processing that you just enabled, head to the page where one of your forms is located on your company's website. Fill out the form in its entirety using a test persona. In this example we used a hypothetical user named John.

  31. Click "Submit"

    Send the test form by clicking the "Submit" button.

  32. Fill out another test on the second form

    Navigate to the other form on your website. Fill out a second form using a different test persona to submit two tests for good measure. In this example, our hypothetical user is Jane.

  33. Click "Submit"

    Send the test form by clicking the "Submit" button.

  34. Type "Email"

    Once your two test forms are sent, head back to the Operations Portal and search "Emails" in the main navigation search bar.

  35. Click "Emails"

    Click "Emails" to access a page with all your system's emails.

  36. Sort the spreadsheet

    To ensure your spreadsheet displays the most recently sent emails at the top, sort the "Sent" column by clicking on the "Arrow" icon next to the word "Sent".

  37. Locate the test emails

    Now that the grid has been sorted, find your test emails. They may be located at the top if you just sent them, or you may have to scroll down the sheet if your system sends many emails.

  38. Click the "Preview" icon

    To view a copy of the email that was sent, click on the "Preview" icon in its row.

  39. Review the test email

    A preview of the email that contains the contents of the form will appear. You can compare this email with the information you used to fill out the test form to ensure your test was successful. You can do this for all the test forms you filled out.

In this article