This document is for an older version of

Freeform

.

View latest version →

Freeform Freeform for ExpressionEngine

Upgrading from Freeform 3.x to Freeform Classic 4+

WARNING

There is no migration utility in Freeform Classic 4.x+ to upgrade from Freeform 3.x. If using EE2, Freeform 3.x users should upgrade to Freeform 4.x on EE2 first, then to EE3 and Freeform 5.x+. Freeform Classic 4.x/5.x/6.x all virtually have the same feature set.

Some of the key changes for Freeform Classic 4.x+ is that forms are now pre-set in the control panel, and are no longer "loose" like they used to be in Freeform 3.x. This means that you must take the time to set up your forms in the control panel, and correctly assign custom fields and notifications templates. This also means that you will see large performance benefits as each form has its own table in the database (whereas all forms shared one in Freeform 3.x), as well as robust managing and administrating of forms and their submissions.

Freeform Classic 4.x+ also introduces the concept of field types, just like you have for channel fields. It allows you to smartly create and manage a wide variety of field types, giving you more flexibility in the data you collect, and more control in how it displays in the front end templates, notification templates, and control panel. One key difference between Freeform 3.x and 4.x+ is how files/attachments are handled. Freeform Classic now contains a File Upload field type, allowing you enormous flexibility in how you handle, store and display file attachments.

Lastly, new to Freeform Classic 4.x+ is a built in Composer tool, which is an intuitive and enjoyable drag and drop interface to create your forms. In Freeform Classic 4.x+, you can create and manage your forms in either the new Composer tool, or the traditional approach within EE templates (like Freeform 3.x does). Freeform Classic 4.x+ allows you to have some forms that are Composer-built, and some that are EE template-based - it's your choice!

{exp:freeform:form}

There are a variety of parameters that have been renamed, while several are obsolete because of Freeform's new field types. Variables, variable pairs, and conditionals are all now prepended with freeform:.

Parameters

  • collection --> changed to form_name
  • allowed_file_types --> now controlled directly per upload fieldtype
  • file_upload --> file uploading now done with upload fieldtype
  • notify --> changed to admin_notify (or can be set in the control panel per form)
  • onsubmit --> use form:ATTRIBUTE_NAME (ex: form:onsubmit)
  • send_attachment --> now controlled directly in notification templates
  • send_user_attachment --> now controlled directly in notification templates
  • send_user_email --> changed to notify_user
  • template --> changed to admin_notification_template
  • user_email_template --> changed to user_notification_template (also see user_email_field)
  • reply_to --> now part of notification templates (controlled in control panel)
  • reply_to_name_field --> now part of notification templates (controlled in control panel)
  • reply_to_email_field --> now part of notification templates (controlled in control panel)
  • output_json --> use ajax now
  • ajax_request --> use ajax now

Variables

  • name --> no longer exists. Use logged_in_screen_name to achieve same effect.
  • email --> no longer exists. Use logged_in_email to achieve same effect.
  • captcha --> changed to freeform:captcha
  • recipient_name1 --> changed to freeform:recipient_name1
  • recipient_value1 --> changed to freeform:recipient_value1

Variable Pairs

  • recipients --> changed to freeform:recipients

Conditionals

  • if duplicate --> changed to if freeform:duplicate
  • if not_duplicate --> changed to if freeform:not_duplicate
  • if captcha --> changed to if freeform:captcha

Form Fields

  • captcha --> changed to freeform:captcha
  • file1 --> file uploading now done with upload fieldtype

{exp:freeform:entries}

In addition to a parameter name change, all of the variables, variable pairs, and conditionals in the Freeform:Entries tag need to be updated as Freeform Classic 4.x+ now prepends them with freeform:.

Parameters

  • collection --> changed to form_name

Variables

  • author_id --> changed to freeform:author_id
  • attachment_count --> changed to freeform:attachment_count
  • collection_name --> changed to freeform:form_name (also see freeform:form_label)
  • count --> changed to freeform:count
  • edit_date --> changed to freeform:edit_date
  • entry_date --> changed to freeform:entry_date
  • entry_id --> changed to freeform:entry_id
  • gmt_edit_date --> no longer exists
  • gmt_entry_date --> no longer exists
  • group_id --> no longer exists. Use author_id in conjunction with the {exp:member:custom_profile_data} tag.
  • ip_address --> changed to freeform:ip_address
  • reverse_count --> changed to freeform:reverse_count
  • switch --> changed to freeform:switch
  • total_entries --> changed to freeform:total_results or freeform:absolute_results
  • template --> no longer exists
  • FREEFORM_FIELD_NAME --> changed to freeform:field:FIELD_NAME

Variable Pairs

  • attachments --> now controlled directly per upload fieldtype

Conditionals

  • if no_results --> changed to if freeform:no_results

{exp:freeform:count}

This template tag no longer exists in Freeform Classic 4.x+, and there is currently no replacement approach available.