Journey Scripting > Actions > Form Selector

Form Selector

Offers the same functionality as the Form action, but allows any CSS selector to be used to fill in the form fields rather than just the input name.

Parameters

Name Required Description Example
Type Yes The action type FormSelector
Selector Yes The form selector #body > form
Fields Yes Key->Value object of field values (See example)

Example

Here we're filling out a form identified by #body > form with two fields using CSS selectors rather than input names.

{
    "Type":"FormSelector",
    "Selector":"#body > form",
    "Fields":{
        "fieldset .colspan:nth-child(3) input[type=radio]":"1",
        ".subformel > div:nth-child(2) input.aftextinput":"Some data"
    }
}