Formidable Pro for WordPress forms offers a variety of shortcodes, or shortcuts, which can be used to easily accomplish a number of different tasks. These shortcodes can do anything from displaying an edit link to calculating a statistic from your form entries. Shortcodes can be inserted on any page, post, View, text widget, or even an HTML field in a form. Below is a complete list of all the shortcodes provided by Formidable.
Display a list of entries
Add a list of entries to a page, post, or widget. Just replace 'x' with the ID of your form. Each item in the list can be used as a link to view or edit the entry. The list can be a dropdown, a collapsed list, or a full list. By default, each list item will be the entry creation date, however, this can be customized. For more information, see how to Display a List of Entries.
Display a table of entries
Display all entries from a form in a table without adding any HTML. Just replace 'x' with the ID of your form. Customization of this table is limited. If you need more control, you can create a View. For more information on this shortcode, click here.
Display a single entry in a table
Display the content from a single entry in a table. Just replace 'x' with the ID of the entry to display. The presentation of data is not customizable in this shortcode. If you need more control, you can create a View. For more information on this shortcode, click here.
Set values for views and forms
This shortcode allows you to set values, or parameters, that can be used within Views and forms. Once parameters are set using this shortcode, they can be used to filter Views, to set default values within forms, and to further customize form and View interactions. For more information, click here.
Get a value from an entry
[frm-field-value field_id=x entry_id=y]
You may get the value from a field and display it on a page, post, View or in a field from a different form. See Get a Value from an Entry for more information.
Add an edit link
In pages and posts
[frm-entry-edit-link id=x label="Edit" page_id=y]
In Views and forms
[editlink location="front" label="Edit" page_id=2]
You may insert an edit link on any page, post, or View to allow users to easily edit or update an entry. Before an edit link will work correctly, you need to set up your form to allow editing for a Single Entry or Multiple Entries. For more information on edit links, click here.
Insert a link to update a field
[frm-entry-update-field id=x field_id=y value="new value"]
This shortcode adds an Update link that changes the value of a single field in a single entry via Ajax. If the current value of that field is the same as the value parameter in your shortcode, the link will not be seen. For more information on this shortcode, click here.
Add a delete link
In pages and posts
[frm-entry-delete-link id=x page_id=y label="Delete"]
In Views and forms
Allow users to easily delete entries by adding a delete link to a page, post, form, or View. When a user clicks on the delete link, the specified entry will be deleted. For more information, see how to Allow Users to Delete Entries.
Publish a form
This shortcode can be used to publish your form wherever you would like. Just replace x with the ID of your form. For more information, see how to publish a form.
Publish a view
[display-frm-data id=x filter=1]
Publish a View on a page, post, or within another Views using this shortcode. Just replace 'x' with the ID of the View. Read more about how to publish a view.
Display repeating section data
Use the [foreach] shortcode to display entries from a Repeating Section in a View or email. The [foreach] shortcode allows you to group field values together when they are from the same row in the Repeating Section.
[foreach 100]  -  [/foreach]
Replace 100 with the field ID of the Repeating Section. Replace 101 and 102 with the field IDs that are inside of the Repeating Section.
Insert field totals and statistics
[frm-stats id=x type=count]
Calculate a variety of different statistics from your form entries using this shortcode. Replace 'x' with the ID of your form. You can calculate a total, average, entry count, maximum, minimum, etc. For complete information about this shortcode and its parameters, click here.
Calculate a value
[frm-math]100 - [frm-stats id=100 type=count][/frm-math]
Calculate the value of a math expression in a View, post, page, or anywhere else WordPress shortcodes work. You can use fixed numbers or shortcodes for the values in your math expression. In a View, Email Notification, or Success message, you can also use field shortcodes, e.g. . You can use addition (+), subtraction (-), multiplication (*), division (/), and parentheses in your math expression. Learn more about the frm-math shortcode.
Insert a graph
You may display a graph of the results of a form on any page, post, View, or form. Just replace 'x' with the ID of your form. To see what your graph options are, go into your form and click on “Reports". Learn more about the frm-graph shortcode.
Insert a search form
Add a search bar to any page, post, widget, or View using this shortcode. This search bar is specifically meant to search Views, an entry list, or a Formidable table of entries. For more information on this shortcode, see Insert a Search Form.
If you have a UserID field in your form, you can display information from the selected user's profile in a View, email, or confirmation message. The UserID shortcodes can be found in the Advanced section of the Customization panel which is located in the right sidebar when you are in your form Settings or a View. The complete list of UserID shortcode parameters are listed on the UserID field page.
A Customization panel is located in the right sidebar when you are in your form Settings or a View. The bottom of the Insert Fields section contains the following shortcodes which can be used to insert the entry ID, post ID, date and time the entry was created, your site URL, etc.
- Entry ID: Inserts the id of the entry. Usage: [id]
- Entry key: Inserts the key of the entry. Usage: [key]
- Post ID: Inserts the ID of the post created from the entry being displayed. This is applicable only if you are using Formidable Pro to create posts each time a new entry is created. Usage: [post_id]
- User IP: Inserts the IP address of the user who submitted the form. Usage: [ip]
- Entry created at: Inserts the date and time the entry was originally submitted. Usage: [created-at]
- Entry updated at: Inserts the date and time the entry was most recently updated. This will only be applicable if your form allows users to edit. Usage: [updated-at]
- Site URL: Inserts the WordPress URL of your site from the WordPress Settings -> General page. Usage: [siteurl]
- Site name: Inserts the name of your site. Usage: [sitename]
- Single entry link: Inserts [detaillink], which will return the URL for the single entry page. This option will only exist if you selected Both or Calendar as your Display Format. This link will take you to whatever is in your Dynamic Content box, or to a post created upon form submission. Include the <a href="[detaillink]">Entry title</a> tag anywhere you would like to add a link to the detailed entry page. For extra security and to more easily allow multiple Views per page, if a View has detail link parameters defined, ONLY those parameters will be allowed. Also, if a View for a post type is inserted on a page, the link will redirect to the single post page if accessed with the regular detail link.
- Edit entry link: Inserts an edit link which takes the user back to the form for the user to edit. You must first allow users to edit a Single Entry or Multiple Entries for the link to work. Usage: [editlink location="front" label="Edit" page_id=4]. Note: you must replace 4 with the ID of the page that contains your form.
- Rotate even/odd: If you would like to apply different styling to every other listing, insert this tag as a class on the div tag surrounding the desired content: <div class="[evenodd]">The rest of your content here.</div>. The odd listings will call the "odd" class, and the even listings will call the "even" class.
- Entry count: Place [entry_count] in the Before or After Content of a View to show the total number of displayed entries.
- Draft status: Place [is_draft] in a View to display 1 if the entry is a draft and 0 otherwise. You may also use it in a conditional statement: [if is_draft]Draft[/if is_draft].
- Updated By: Show the Display Name of the user who updated an entry most recently. Usage: [updated-by]
A Customization panel is located in the right sidebar when you are in your form Settings or a View. The Advanced section contains the following shortcodes which can be used to show a saved value, show a field label, remove automatically added paragraph tags, truncate text, format dates or numbers, etc.
- Separator: Use a different separator for checkbox field values. By default, this will be a comma. Usage: [125
- Clickable links: Makes a link clickable. Usage: [125 clickable=1]
- Remove links: Removes a link from text. Usage: [125 links=0]
- Sanitize: Replaces spaces with dashes and lowercases all. Use if adding an HTML class or ID. Usage: [125 sanitize=1]
- Sanitize URL: Replaces all HTML entities with a URL safe string. Usage: [125 sanitize_url=1]
- Truncate: Truncates text to the specified number of characters. By default, a link is appended to the end of the text. You can use the following parameters to modify or remove this link. Usage: [125 truncate=40]
- More text: By default, this link will be "..." but can be changed with the parameter below. If using Both (dynamic), the link goes to the detail page. Otherwise, it will show in-place. Usage: [125 truncate=100 more_text="Read More"]
- No Link: By default, when truncating text, there will be a link to show the remaining text. To remove this link, use the following shortcode. Please note, the no_link parameter requires the truncate parameter to also be used. Usage: [x truncate=100 no_link=1]
- Time ago: If you have a date field in your form, this shortcode will display the number of days, weeks, months, or years ago the entered date is from today's date. You can also use this with the created_at or updated_at shortcode. If using time_ago with the created_at or updated_at shortcode, you may determine how many time measurements should appear. For example, you can use [created_at time_ago=3] to show "2 weeks 1 day 23 hours". If you use [created_at time_ago=1], you will see "2 weeks" without the days and hours. Usage: [125 time_ago=1] or [created_at time_ago=1]
- Date format: Change the format of the displayed date. Usage: [125 format="d-m-Y"]
- Number format: Change the format of a displayed number. You can change the number of decimals places shown and the separator for thousands. Usage: [125 decimal=2 dec_point="." thousands_sep=","]
- Field label: Shows the label of a field. Usage: [125 show="field_label"]
- Field description: Shows the description of a field. Usage: [125 show="description"]
- Saved value: Shows the saved value of a field. This is most helpful when you are using separate values. Usage: [125 show="value"]
- No auto P: Removes any automatically added paragraph tags from a field. This is most useful with paragraph fields. Usage: [125 wpautop=0]
- Remove HTML: Removes any HTML from a field. Usage: [125 striphtml=1]
Note: In all usage examples, you must replace 125 with the ID of a field in your form.
There are several shortcodes which can be used to autopopulate fields in your form with your user's first and last name, today's date, the current time, user meta, a parameter in the URL, etc.
- Current date: Insert today's date. Usage: [date]
- Current time: Insert the current time. Usage: [time]
- Email address: Get the email address from the logged-in user's profile. Usage: [email]
- Username: Get the username/login from a logged-in user's profile. Usage: [login]
- Display name: Get the display name from a logged-in user's profile. Usage: [display_name]
- First name: Get the first name from a logged-in user's profile. Usage: [first_name]
- Last name: Get the last name from a logged-in user's profile. Usage: [last_name]
- UserID: Get the user ID number from a logged-in user's profile. Usage: [user_id]
- User meta: Get any user meta from a logged-in user's profile if you are using the Registration add-on. Usage: [user_meta key="address"]
- Post ID: Insert the ID of the post where your form is inserted. Usage: [post_id]
- Post title: Get the title of the post where your form is inserted. Usage: [post_title]
- Post author's email: Insert the email address of the post author from the post your form resides on. Usage: [post_author_email]
- Post meta: Get any information saved to custom fields in the post your form resides on. Usage: [post_meta key="my_custom_field_name"]
- IP address: Insert the IP address of the current user. Usage: [ip]
- Auto increment: Insert a number that increases by one with each entry for the form with [auto_id].
- Get parameter: Get a value from the URL, which may be posted from the previous page or from the WP Query object. If the parameter is blank in the URL, you can set a default with default="Default Value". Usage: [get param="my_parameter_name" default="Default"]
- Server values: Get the URL of the current page or the referring page. Use [server param="REQUEST_URI"] in a text field/hidden field to get the URL of the current page. Use [server param="HTTP_REFERER"] to get the URL of the previous page. This shortcode allows you to access PHP's $_SERVER superglobal. Check here to see the full set of values available.
For more information on default values, refer to the dynamic default values page.
[if 125 equals="Yes"]Content[/if 125]
Conditional statements like this can be used in several places to conditionally show certain content. They are most commonly used in Views and email messages, but they can also be used to direct users to a different URL or display a different confirmation message depending on a response in the form. See a complete list of conditional statement shortcodes.
The [frm-condition] shortcode can be used to compare values before displaying something on the page. It can be used just like conditional statements, but isn't limited to views. Read more about how to compare two values for display.
To view Dynamic Field shortcode options, click here.
When you are in your form's "Customize HTML" tab, a Customization panel will appear in the right sidebar. The Customization panel will contain the following shortcodes which will make it a little easier to customize your form.
- Field ID: Inserts the ID of the corresponding field. Usage: [id]
- Field key: Inserts the key of the corresponding field. Usage: [key]
- Field name: Inserts the name or label of the corresponding field. Usage: [field_name]
- Field description: References the description for each field. This shortcode will not do anything if you have not added a description to the field. You may move the field description above, below, or inline with the field. Usage: [description]
- Label position: Returns the label position class. Usage: [label_position]
- Required label: Inserts the required field label, which is often an asterisk. You may move this required label anywhere within the corresponding field container. Usage: [required_label]
- Input field: References the input portion of the field. You may move the input or may add styling inside such as [input style="color:red"]. Usage: [input]
- Single option: In order to edit individual options for radio buttons or checkboxes, you need to go into the correct box and change [input] to [input opt=1], [input opt=2], continuing until you have defined each option for this field. The “Single Option” button can help you break out these options more quickly. You can use HTML or inline CSS to customize the options or add elements in between. For examples, see the Customize HTML page.
- Hide option label: Hides the option labels for radio buttons and checkboxes. If you would like a checkbox or radio button with no accompanying text, use this shortcode. Usage: [input label=0]
- Required class: Inserts the class used for required fields. Usage: [required_class]
- Error class: Inserts the class used when there is an error with the field entry. Usage: [error_class]
- Form name: Inserts the name of the form. This may only be placed in the before or after fields. Usage: [form_name]
- Form description: Inserts the form description if you have added one. This may only be placed in the before or after fields. Usage: [form_description]
- Form key: Inserts the form key for easy reference. Usage: [form_key]
- Delete entry link: Inserts a link to delete an entry. For this link to work correctly, you must first allow users to delete entries. Usage: [deletelink]
- Button label: Inserts the label you have selected for your Submit button. This label is entered on the form Settings page. Usage: [button_label]
- Button hook: Inserts the action of the Submit button. This should not be removed if you make any changes to your Submit button HTML. Usage: [button_action]
File upload fields
- Display Image: Display the image instead of showing the image URL with show_image=1.
- Link to full size image: Link to the full size image with add_link=1. Goes well with or without show_image=1.
[x show_image=1 add_link=1]
- Image size: Set the image display size using either size=thumbnail, size=medium, or size=full.
<img src="[25 size=full]" alt="" />
- Show filename: Display the filename of an uploaded file.
- Show attachment ID: Display the attachment ID of an uploaded file.