问题
I have a form deployed as a Web App through Google Apps Script and a couple fields allow you to select multiple values (ie. Like a multi-select dropdown). If I have multiple values with the same identifier in the GET request I only get the first one as a parameter in apps script.
How can I use apps script to capture multiple GET parameters with the same identifier?
回答1:
Figured this out.
In your doGet
or doPost
function, instead of calling e.parameter
you need to call e.parameters
to get multiple parameters with the same name as arrays.
Documentation: https://developers.google.com/apps-script/guides/web?hl=en#url_parameters
来源:https://stackoverflow.com/questions/34968911/how-to-capture-multiple-get-parameters-with-the-same-identifier-in-google-apps-s