Populate a picklist on Form using a centralized source | Community
Skip to main content
Level 2
January 16, 2025
Solved

Populate a picklist on Form using a centralized source

  • January 16, 2025
  • 1 reply
  • 880 views

Hello community,

We are in the process of converting more than 100 forms into Marketo Forms. These forms will include a picklist (select dropdown) where users will be asked to select the product they are interested in. Our client has a centralized database that contains the labels and values for the options that should appear in these selects. We would like to know if it is possible to use this database as the data source for the selects in the forms, ensuring that the values remain centralized and up-to-date.

We’ve looked into the possibility of using the Marketo Forms API, but we are exploring other alternatives that might offer better scalability. 

Any help or suggestions would be greatly appreciated!

Best answer by SanfordWhiteman

We’ve looked into the possibility of using the Marketo Forms API, but we are exploring other alternatives that might offer better scalability. 


You mean the Marketo Forms JS API? What could possibly be more scalable than that? Or are you talking about the REST API?

 

If you serve up the lists as a JSON feed (or, if necessary, JSONP), it’s trivial to populate the <select> <options> in realtime. Just listen for whenReady (or, if the field is used in Visibility Rules, whenRendered).

1 reply

SanfordWhiteman
SanfordWhitemanAccepted solution
Level 10
January 16, 2025

We’ve looked into the possibility of using the Marketo Forms API, but we are exploring other alternatives that might offer better scalability. 


You mean the Marketo Forms JS API? What could possibly be more scalable than that? Or are you talking about the REST API?

 

If you serve up the lists as a JSON feed (or, if necessary, JSONP), it’s trivial to populate the <select> <options> in realtime. Just listen for whenReady (or, if the field is used in Visibility Rules, whenRendered).

Level 2
January 17, 2025

I was talking about the Forms JS API. We were reviewing it, and you're right, it is scalable. It's just that we had something else in mind, like being able to populate the select options directly from the Marketo panel to have this configuration there. But looking at the options, I think we'll go with the Forms JS API.

 

Thank you very much for your response.

SanfordWhiteman
Level 10
January 18, 2025

If you really want a visual editor for the options, just create a standard form with only that field on it. The form descriptor is always available over JSONP, so it becomes your global source.