Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
* Fluent Forms Extra Smartcodes on form integration feeds
* This code will add a new item on the smartcode dropdown.
* if you don't want to show the smartcode then you may skip this.
add_filter('fluentform_form_settings_smartcodes', function ($groups) {
$groups[0]['shortcodes']['{my_custom_smartcode}'] = 'Custom All Data';
return $groups;
* Callback for {my_custom_smartcode} smartcode for integration feed
add_filter('fluentform_shortcode_parser_callback_my_custom_smartcode', function ($return, $instance) {
$form = $instance::getForm();
$entry = $instance::getEntry();
$formFields = \FluentForm\App\Modules\Form\FormFieldsParser::getEntryInputs($form);
$inputLabels = \FluentForm\App\Modules\Form\FormFieldsParser::getAdminLabels($form, $formFields);
$response = \FluentForm\App\Modules\Form\FormDataParser::parseFormSubmission($entry, $form, $formFields, true);
$html = 'This is your html or whatever you want to create from the available data';
return $html;
}, 10, 2);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment