This tag is used in conjunction with the [MM_Form] tag. It outputs form fields that the user can interact with to enter in data.

Attributes


Available field types and other attributes will vary based on the parent form type. Below is a list of supported attributes broken down by form type.



checkout


type (optional) - Indicates the type of form field to create. Acceptable values are input, hidden, custom or custom-hidden. The default value is input.


input - Form fields of type input output a standard HTML form element that the user can interact with to enter in information. Based on the value name attribute MemberMouse will render the appropriate HTML form element. For example, a dropdown will be rendered for selecting a Country and an input field will be rendered for entering in their first name. The name attribute is required for input form fields.


hidden - Form fields of type hidden output a hidden HTML element which indicates to MemberMouse that the name associated with this form field can be ignored when validating the form. For example, when purchasing a product, billing address is required by default so MemberMouse won't allow the user to proceed until a billing address has been provided. By using a form field of type hidden for billing address, you're instructing MemberMouse to allow the form to be submitted without providing a billing address. This is useful when you want to provide a minimal checkout form in cases where you don't require certain information. The name attribute is required for hidden form fields. The value attribute is optional.


custom - Form fields of type custom output an HTML form element that the user can interact with to enter in information associated with custom fields you've configured in MemberMouse. The id attribute is required for custom form fields. The isRequired attribute is optional.


custom-hidden - Form fields of type custom-hidden output a hidden HTML form element that stores data associated with custom fields you've configured in MemberMouse. The id attribute is required for custom form fields. The isRequired attribute is optional. Hidden custom fields are perfect for storing information related to the order that the user doesn't enter. For example, you could track the ad name they came from, which keyword they used to find your product, etc. All you need to do is pass a querystring parameter to the page in the following format: cf_{ID} where {ID} is replaced by the ID of the custom field. Here's an example: http://mysite.com/checkout?cf_1=banner-1&cf_2=marketing. In this example, we're passing banner-1 as the value for the custom field with ID 1 and marketing as the value for the custom field with ID 2.


name (conditional based on field type) - This field is required for input and hidden field types. It indicates what data is being collected in the field. Below is a table of acceptable values. If a field is optional this means you don't have to include it in the form. If it's required, you have to include it in the form, but in a number of cases you can hide required fields from being seen by setting the type to hidden. Certain names are valid for both input and hidden field types while others are valid just for input fields.


ValueDescriptionOptionalValid Field Types
firstNameCollects the user's first nameNoinput, hidden
lastNameCollects the user's last nameNoinput, hidden
emailCollects the user's email addressNoinput
email-confirmForces the user to confirm their email addressYesinput
usernameCollects the user's usernameYesinput
phoneCollects the user's phone numberNoinput, hidden
passwordCollects the user's passwordNoinput, hidden
captchaForces the user to fill out a captcha field for validationYesinput
billingAddressCollects the user's billing addressNoinput, hidden
billingCityCollects the user's billing cityNoinput, hidden
billingStateCollects the user's billing stateNoinput, hidden
billingZipCodeCollects the user's billing zip codeNoinput, hidden
billingCountryCollects the user's billing countryNoinput, hidden
shippingAddressCollects the user's shipping addressNoinput, hidden
shippingCityCollects the user's shipping cityNoinput, hidden
shippingStateCollects the user's shipping stateNoinput, hidden
shippingZipCodeCollects the user's shipping zip codeNoinput, hidden
shippingCountryCollects the user's shipping countryNoinput, hidden
shippingMethodCollects shipping method the user wants to useNoinput, hidden
shippingSameAsBillingOutputs a checkbox the user can click to indicate whether or not they want to provide a shipping address that's different from their billing address.Noinput
ccNumberCollects the user's credit card numberNoinput
ccExpirationDateCollects the expiration date associated with the user's credit card numberNoinput
ccSecurityCodeCollects the security code associated with the user's credit card numberNoinput
couponCodeCollects the coupon code the user wants to apply to the orderYesinput
giftOutputs a checkbox the user can click to indicate if the product being purchased is a gift.Yesinput


class (conditional based on field type) - This field is optional for input and custom fields. It indicates the CSS class that should be used for the field.

value (conditional based on field type) - This field is optional for hidden fields. It specifies the default data to set for the field specified in the name attribute.


id (conditional based on field type) - This field is required for custom and custom-hidden fields. It specifies the ID of the custom field to collect data for.


isRequired (conditional based on field type) - This field is optional for custom and custom-hidden fields. It indicates whether the custom field should be required. Acceptable values are true and false. The default value is false. This attribute can also be use on input fields that can be hidden. This includes firstName, lastName, phone, password, billingAddress, billingCity, billingState, billingZipCode, billingCountry, shippingAddress, shippingCity, shippingState, shippingZipCode.


default (conditional based on field name) - This field is optional when the name is set to shippingMethod. Here you can specify the key of the shipping method to use as the default. Read this article to learn how to lookup the shipping method key.

customAttributes (conditional based on field type) [MM 2.1.2] - This field is optional for input fields. This attribute can be used to add additional HTML attributes to the HTML input field generated by MemberMouse. Whatever is set in this attribute will be added to the HTML verbatim. For example, if you do the following:

[MM_Form_Field type='input' name='firstName' customAttributes='placeholder="First Name"']


The following HTML will be generated:


<input type="text" id="mm_field_first_name" name="mm_field_first_name" class="mm-textField" placeholder="First Name">


myAccount


none


login


type (optional) - Indicates the type of form field to create. input is the only acceptable value and is also the default value. Form fields of type input output a standard HTML form element that the user can interact with to enter in information. Based on the value name attribute MemberMouse will render the appropriate HTML form element.


name - Indicates what data is being collected in the field. Below is a table of acceptable values.


ValueDescription
usernameCollects the member's username
passwordCollects the member's password
rememberMeOutputs a checkbox allowing the member to specify whether they want the site to remember them so they don't have to login in again then next time they come back.


label (optional) - This field is optional when the field name is set to rememberMe. It specifies the label to output next to the remember me checkbox. The default value is Remember Me.


customAttributes (conditional based on field type) [MM2.4.1+] - This field is optional for input fields. This attribute can be used to add additional HTML attributes to the HTML input field generated by MemberMouse. Whatever is set in this attribute will be added to the HTML verbatim. For example, if you do the following:


[MM_Form_Field name='username' customAttributes='placeholder="Your User Name"']


The following HTML will be generated:


<input type="text" id="log" name="log" class="mm-field" placeholder="Your User Name">



forgotPassword


type (optional) - Indicates the type of form field to create. input is the only acceptable value and is also the default value. Form fields of type input output a standard HTML form element that the user can interact with to enter in information. Based on the value name attribute MemberMouse will render the appropriate HTML form element.


name - Indicates what data is being collected in the field. Below is a table of acceptable values.


ValueDescription
emailCollects the member's email address

customAttributes (conditional based on field type) [MM2.4.1+]  - This field is optional for input fields. This attribute can be used to add additional HTML attributes to the HTML input field generated by MemberMouse. Whatever is set in this attribute will be added to the HTML verbatim. For example, if you do the following:

[MM_Form_Field name='email' customAttributes='placeholder="Email Address"']


The following HTML will be generated:


<input type="text" id="email" name="email" class="mm-field" placeholder="Email Address">



resetPassword


type (optional) - Indicates the type of form field to create. input is the only acceptable value and is also the default value. Form fields of type input output a standard HTML form element that the user can interact with to enter in information. Based on the value name attribute MemberMouse will render the appropriate HTML form element.


name - Indicates what data is being collected in the field. Below is a table of acceptable values.


ValueDescription
passwordCollects the member's new password.
password-confirmCollects the password confirmation. It must match what was entered in the password field.

customAttributes (conditional based on field type) [MM2.4.1+] - This field is optional for input fields. This attribute can be used to add additional HTML attributes to the HTML input field generated by MemberMouse. Whatever is set in this attribute will be added to the HTML verbatim. For example, if you do the following:

[MM_Form_Field name='password' customAttributes='placeholder="New Password"']


The following HTML will be generated:


<input type="password" id="password" name="password" class="mm-field" placeholder="New Password">



1clickPurchase


type (optional) - Indicates the type of form field to create. Acceptable values are input, hidden or custom. The default value is input.


input - Form fields of type input output a standard HTML form element that the user can interact with to enter in information. Based on the value name attribute MemberMouse will render the appropriate HTML form element. For example, a dropdown will be rendered for selecting a Country and an input field will be rendered for entering in a coupon code. The name attribute is required for input form fields.


name (conditional based on field type) - This field is required for input field type. It indicates what data is being collected in the field. Below is a table of acceptable values.


shippingAddressCollects the user's shipping addressinput, hidden
shippingCityCollects the user's shipping cityinput, hidden
shippingStateCollects the user's shipping stateinput, hidden
shippingZipCodeCollects the user's shipping zip codeinput, hidden
shippingCountryCollects the user's shipping countryinput, hidden
shippingMethodCollects shipping method the user wants to useinput, hidden
couponCodeCollects the coupon code the user wants to apply to the orderinput


custom


type (optional) - Indicates the type of form field to create. Acceptable values are custom or custom-hidden. The default value is custom.


custom - Form fields of type custom output an HTML form element that the user can interact with to enter in information associated with custom fields you've configured in MemberMouse. The id attribute is required for custom form fields. The isRequired attribute is optional.


custom-hidden - Form fields of type custom-hidden output a hidden HTML form element that stores data associated with custom fields you've configured in MemberMouse. The id attribute is required for custom form fields. The isRequired attribute is optional. Hidden custom fields are perfect for storing information related to the order that the user doesn't enter. For example, you could track the ad name they came from, which keyword they used to find your product, etc. All you need to do is pass a querystring parameter to the page in the following format: cf_{ID} where {ID} is replaced by the ID of the custom field. Here's an example: http://mysite.com/checkout?cf_1=banner-1&cf_2=marketing. In this example, we're passing banner-1 as the value for the custom field with ID 1 and marketing as the value for the custom field with ID 2.


class (conditional based on field type) - This field is optional for custom fields. It indicates the CSS class that should be used for the field.


id (conditional based on field type) - This field is required for custom and custom-hidden fields. It specifies the ID of the custom field to collect data for.


isRequired (conditional based on field type) - This field is optional for custom and custom-hidden fields. It indicates whether the custom field should be required. Acceptable values are true and false. The default value is false.




 


Usage
[MM_Form type='checkout']

Input Fields:
First Name: [MM_Form_Field type='input' name='firstName']
Last Name: [MM_Form_Field type='input' name='lastName']

Hidden Fields:
[MM_Form_Field type='hidden' name='billingAddress']
[MM_Form_Field type='hidden' name='billingCity']
[MM_Form_Field type='hidden' name='billingState' value='TX']
[MM_Form_Field type='hidden' name='billingCountry' value='US']

Custom Fields:
Birthday: [MM_Form_Field type='custom' id='1' isRequired='true']
Height: [MM_Form_Field type='custom' id='3' isRequired='false']

Hidden Custom Field:
[MM_Form_Field type='custom-hidden' id='5']

...other form SmartTags...
[/MM_Form]