Not yet using the Miniform Form Creator? Try it now
Do you like this free module? Please consider a small donation through PayPal

Dropdown lists

Assuming you have read the basics for inputfields and their naming, the same rules apply for dropdows lists.

A dropdownlist has a select tag with the name and multiple option tags with calue fields for the rows in the list.
Just like with radio buttons and checkboxes you can preselect the row that was the choice in a previous submit. In case of dropdown lists this should be done with selected="selected".
A special "remember field" is used to set these values.
The field is built using the fieldname + "selected" + the value of the selected row, and like always in uppercase characters and between curly brackets.

See the example below (from the full contactform template) for a full working required dropdown list.

<select class="{DEPARTMENT_ERROR}" id="department" name="mf_r_department">
  <option value="">-- Please select --</option>
  <option {DEPARTMENT_SELECTED_CUSTOMER_SERVICE} value="Customer service">Customer service</option>
  <option {DEPARTMENT_SELECTED_SALES_TEAM} value="Sales team">Sales team</option>
  <option {DEPARTMENT_SELECTED_SUBSCRIPTIONS} value="Subscriptions">Subscriber service</option>
</select>

In this example the first option will have an empty value and is seen as no selection. This way the form validation will mark this as not selected.