add_action('arf_outside_global_setting_block', 'your_function', 10, 2);
function your_function($settings, $active_license){
//Do Your Action
echo "General Settings HTML Block.";
}
- arf_outside_global_setting_block
This action hook is useful to add additional general settings block from outside in ARForms at global settings.
- arf_update_global_setting_outside
This filter is useful to display general settings options values from outside at global settings.
- arf_autoresponder_global_setting_block
This action hook is useful to add email marketing tool with its configuration options from outside in ARForms at global settings.
add_filter('arf_update_global_setting_outside', 'your_function', 10, 2);
function your_function($outside_settings,$values){
//Display values from outside.
$outside_settings['OUTSIDE-OPTION'] = $values['OUTSIDE-OPTION'];
return $outside_settings;
}
add_action('arf_autoresponder_global_setting_block', 'your_function', 10, 2);
function your_function($autoresponder_types, $active_license){
//Do Your Action
echo "Email Marketing Tool HTML Block.";
}
- arf_import_update_field_outside
This filter is useful to update form options from outside while importing form in ARForms.
- include_outside_js_css_for_preview_header
This action hook is useful to load external js/css at preview header.
- include_outside_js_css_for_preview_footer
This action hook is useful to load external js/css at preview footer.
- arfbeforeupdateform
This hook is useful to perform action before save form at form editor.
- arfafterupdateform
This hook is useful to perform action after save form at form editor.
- arf_save_form_options_outside
This filter is useful to save additional form options from outside in ARForms while saving form in form editor.
- arf_update_form_option_outside
This filter is useful to update additional form options values from outside in ARForms while updating form in form editor.
- arf_predisplay_form
This action hook is useful to display additional content or input in form or to execute any action from outside before displaying form in front.
- arf_current_autoresponse_set_outside
This filter is useful to get Opt-ins enabled status from outside to display active in Opt-ins popup at form editor.
- arfgetpagedfields
This filter hook is useful to return fields from outside to be added in next/previous pages before changing page at paginated form.
- arf_prevent_auto_save_form
This filter is useful to prevent Auto save form progress conditionally from outside if enabled this option for form.
- arf_after_success_massage
This action hook is useful to display additional content after success message on submit form successfully.
- arf_update_form_return_json_outside
This filter is useful to return form option added from outside in ARForms which will be added in json encoded returned values after form submission.
- arf_after_submit_sucess_outside
This filter is useful to get script to be executed after form submission from outside in ARForms.
- arf_is_resetform_aftersubmit
This filter is useful to return flag whether form to be reset from outside after form submission or not in ARForms.
- arf_is_resetform_outside
This filter is useful to reset form from outside after form submission in ARForms.
- arf_hide_forms
This filter hook is useful to handle form submission action to hide form from outside.
- arf_check_condition_on_subscription
This filter is useful to check if is there condition set on subscription to enable opt-ins after form submission.
- arf_afterdisplay_form
This action hook is useful to append additional content for form like <style></style> or <script></script>
add_filter('arf_import_update_field_outside', 'your_function', 10, 3);
function your_function($new_option_values, $old_field_id, $form_id){
//Update new options with new values.
return $new_option_values;
}
add_action('include_outside_js_css_for_preview_header', 'your_function');
function your_function(){
//Do Your Action
//enqueue external js/css in header.
}
add_action('include_outside_js_css_for_preview_footer', 'your_function');
function your_function(){
//Do Your Action
//enqueue external js/css in footer.
}
add_action('arfbeforeupdateform', 'your_function', 10, 3);
function your_function($form_id, $values, $create_link = false){
//Do Your Action
echo "Form options HTML";
}
add_action('arfafterupdateform', 'your_function', 10, 4);
function your_function($form_id, $values, $create_link = false, $is_ref_form = 0){
//Do Your Action
echo "Form options HTML";
}
add_filter('arf_save_form_options_outside', 'your_function', 10, 3);
function your_function($options, $values, $form_id){
$options['outside_options'] = $values['outside_options'];
return $options;
}
add_filter('arf_update_form_option_outside', 'your_function', 10, 4);
function your_function($options,$json_data,$old_value_id,$new_value_id){
if($options['outside_options'] == $old_value_id){
$options['outside_options'] = $new_value_id;
}
return $options;
}
add_action('arf_predisplay_form', 'your_function', 10, 1);
function your_function($form){
//Do Your Action
echo "Additional content or inputs.";
}
add_filter('arf_current_autoresponse_set_outside', 'your_function', 10, 2);
function your_function($active, $data){
$opt-in_data = @maybe_unserialize(isset($data[0]['OPT-IN']) ? $data[0]['OPT-IN'] : '' );
if (isset($opt-in_data['enable']) && $opt-in_data['enable'] == 1) {
$active = 'OPT-IN';
}
return $active;
}
add_filter('arfgetpagedfields', 'your_function', 10, 3);
function your_function($fields, $form_id, $error = false){
//Return field conditionally in paginated form.
return $fields;
}
add_filter('arf_prevent_auto_save_form', 'your_function', 10, 2);
function your_function($flag, $form){
//Return flag conditionally to prevent auto save form progress.
if($form->id == 'FORM-ID') {
$flag = true;
}
return $flag;
}
add_action('arf_after_success_massage', 'your_function', 10, 1);
function your_function($form){
//Do Your Action
echo "Additional content after form submision.";
}
add_filter('arf_update_form_return_json_outside', 'your_function', 10, 2);
function your_function($json_data,$options){
if( isset($options['outside_option']) ){
$json_data['outside_option'] = $options['outside_option'];
}
return $json_data;
}
add_filter('arf_after_submit_sucess_outside', 'your_function', 10, 2);
function your_function($return_script,$form){
$return_script .= "<script type='text/javascript'>";
//Script to execute after form submission.
$return_script .= "</script>";
return $return_script;
}
add_filter('arf_is_resetform_aftersubmit', 'your_function', 10, 2);
function your_function($flag, $form){
//Return Form Reset Flag.
$flag = false;
return $flag;
}
add_filter('arf_is_resetform_outside', 'your_function', 10, 2);
function your_function($flag, $form){
//Reset Form.
$flag = false;
return $flag;
}
add_filter('arf_hide_forms', 'your_function', 10, 2);
function your_function( $hide_forms, $form_id ){
$hide = true;
return $hide;
}
add_filter('arf_check_condition_on_subscription', 'your_function', 10, 2);
function your_function($form, $entry_id){
//Return condition status on subscription.
return false;
}
add_action('arf_afterdisplay_form', 'your_function', 10, 1);
function your_function($form){
//Do Your Action
echo "Styling / Javascript code.";
}
- arfavailablefields
This filter hook is useful to add field in Basic Form Elements list at form editor from outside which can be drag and drop in form after.
- arfaavailablefields
This filter hook is useful to add field in Advance Form Elements list at form editor from outside which can be drag and drop in form after.
- arf_new_field_array_filter_outside
This filter is useful to add or change HTML for field control block from outside in form editor.
- arf_new_field_array_materialize_filter_outside
This filter is useful to add or change HTML for material inputs control block from outside in form editor.
- arf_positioned_field_options_icon
This filter is useful to add or customize array of icons for particular field from outside.
- arf_controls_added_class_outside_materialize
This filter hook is useful to add class to the wrapper of input control from outside.
- arf_input_style_label_position_outside
This filter is useful to add field in array of fields from outside for which label style is standard in materialize form editor like Slider, Radio.
- arf_change_json_default_data_ouside
This filter is useful to append or change in JSON array of field data from outside for particular field.
- arf_form_fields_outside
This filter is useful to append or change JSON array for default css of field from outside.
- arf_field_option_model_outside
This action hook is useful to add field options for field customization in form editor which is added from outside in ARForms.
- arf_field_values_options_outside
This filter is useful to add field in array of fields from outside for which Edit options icon is displayed on hover like checkbox, select at form editor.
- arf_add_more_field_options_outside
This filter is useful to add additional field options from outside for fields in ARForms.
- arfcustomhtml
This filter is useful to customize default HTML for fields from outside in form.
- arfdisplayfieldhtml
This filter hook checks if to place default field HTML for particular field type from outside.
- arfothercustomhtml
This filter is useful to return custom HTML for fields from outside for which field default HTML flag is false by arfdisplayfieldhtml filter.
- arf_outsite_print_style
This action hook is useful to print css in maincss of form for fields which are added from outside in ARForms.
- arf_change_field_icons_outside
This filter hook is useful to change field icons from outside while importing form in ARForms.
- arf_installed_fields_outside
This filter hook collects all field types from outside while importing form which can be skipped to import if respective addon is not active.
- arf_check_for_draw_outside
This filter is useful to check status if is there form fields to be populated from outside in ARForms.
- arf_drawthisfieldfromoutside
This filter is useful to populate form fields from outside in ARForms.
- arf_default_value_array_field_type
This filter is useful to allow to set default value checked for field added from outside in form.
- arf_default_value_array_field_type_from_itemmeta
This filter is useful to allow to set default value selected for field added from outside in form.
- arf_field_wise_js_css
This filter returns array of js and css for particular field to enqueue in form.
- arf_load_bootstrap_js_from_outside
This action hook is useful to load external bootstrap js/css for fields which are added from outside in ARForms.
- arf_check_for_running_total_field
This filter is useful to return function for running total on change input values.
- arf_populate_field_from_outside
This filter hook is useful to populate field in form which is added from outside in ARForms.
- arfbeforefielddisplay
This filter hook is useful to customize the field options before displaying them.
- arfafterdisplayfield
This hook is useful to customize fields displaying at preview and front page.
- arfgetdefaultvalue
This filter hook is useful to change or set default value for fields from outside.
- arfsetupnewentry
This filter is useful to change value or default value or other options of fields from outside before displaying form.
- arfsetupnewfieldsvars
This filter hook is useful to customize field values from outside.
- arf_disply_required_field_outside
This filter hook is useful to change required status of field from outside.
- arf_onchange_only_click_event_outside
This field is useful to add outside field in array of fields for which onChange event is binded to count running total values.
- arfbeforereplaceshortcodes
This filter is useful to replace custom HTML shortcodes with original HTML content from outside before populating field in form.
- arfreplaceshortcodes
This filter is useful to replace shortcode in field HTML from outside in ARForms.
- arffieldsreplaceshortcodes
This filter hook is useful to replace shortcode with particular entry values in field entry.
add_filter('arfavailablefields', 'your_function', 10, 1);
function your_function($form_elements){
//Add field in basic form elements list at form editor.
$outside_field = array(
'FIELD-TYPE' => array(
'icon' => 'FIELD ICON',
'label' => 'FIELD LABEL'
)
);
return array_merge($form_elements, $outside_field);
}
add_filter('arfaavailablefields', 'your_function', 10, 1);
function your_function($form_elements){
//Add field in advance form elements list at form editor.
$outside_field = array(
'FIELD-TYPE' => array(
'icon' => 'FIELD ICON',
'label' => 'FIELD LABEL'
)
);
return array_merge($form_elements, $outside_field);
}
add_filter('arf_new_field_array_filter_outside', 'your_function', 10, 4);
function your_function($fields, $field_icons, $json_data, $positioned_field_icons){
//Add HTML for particular field.
$field_html = array(
'FIELD-TYPE' => 'HTML FOR FIELD'
);
return array_merge($fields, $field_html);
}
add_filter('arf_new_field_array_materialize_filter_outside', 'your_function', 10, 4);
function your_function($fields, $field_icons, $json_data, $positioned_field_icons){
//Add HTML for particular material input.
$field_html = array(
'FIELD-TYPE' => 'HTML FOR MATERIAL INPUT BLOCK'
);
return array_merge($fields, $field_html);
}
add_filter('arf_positioned_field_options_icon', 'your_function', 10, 2);
function your_function($positioned_field_icons, $field_icons){
//Add array of field icons for particular field type.
$positioned_field_icons[FIELD-TYPE] = "{$field_icons['field_require_icon']} {$field_icons['field_delete_icon']} {$field_icons['arf_field_move_icon']}";
return $positioned_field_icons;
}
add_filter('arf_controls_added_class_outside_materialize', 'your_function', 10, 2);
function your_function($class, $field_type){
if($field_type == FIELD-TYPE)
{
$class .='CLASS';
}
return $class;
}
add_filter('arf_input_style_label_position_outside', 'your_function', 10, 3);
function your_function($fields, $inputs_style, $field_type){
if($inputs_style == 'material'){
if($field_type == FIELD-TYPE){
array_push($fields,FIELD-TYPE);
}
}
return $fields;
}
add_filter('arf_change_json_default_data_ouside', 'your_function', 10, 1);
function your_function($field_json){
$field_data = JSON FORMAT DATA;
$field_json['field_data']['FIELD-TYPE'] = $field_data;
return $field_json;
}
add_filter('arf_form_fields_outside', 'your_function', 10, 2);
function your_function($field_json, $input_style){
foreach ($field_json->field_data as $key => $value) {
foreach ($value as $data_key => $data_value) {
if($data_key == 'KEY'){
$field_json->field_data->$key->$data_key = DEFAULT VALUE;
}
}
}
return $field_json;
}
add_action('arf_field_option_model_outside', 'your_function');
function your_function(){
//Do Your Action
echo "Field options HTML";
}
add_filter('arf_field_values_options_outside', 'your_function', 10, 1);
function your_function($fields){
$count = count($fields);
$fields[$count+1] = FIELD-TYPE;
return $fields;
}
add_filter('arf_add_more_field_options_outside', 'your_function', 10, 2);
function your_function($field_options, $field_type){
//Add field options and value.
if($field_type == 'FIELD-TYPE') {
$field_options['CUSTOM-OPTION'] .= 'DEFAULT VALUE FOR CUSTOM OPTION';
}
return $field_options;
}
add_filter('arfcustomhtml', 'your_function', 10, 2);
function your_function($default_html, $field_type){
//Customize HTML For Field.
if($field_type == 'FIELD-TYPE') {
$default_html .= 'CUSTOMIZED HTML FOR FIELD';
}
return $default_html;
}
add_filter('arfdisplayfieldhtml', 'your_function', 10, 2);
function your_function($flag = true, $field_type){
//Return flag to place default field HTML.
if($field_type == 'FIELD-TYPE') {
$flag = false; // Place custom HTML.
}
return $flag;
}
add_filter('arfothercustomhtml', 'your_function', 10, 2);
function your_function($default_html, $field_type){
//Return Custom HTML For Field
if($field_type == 'FIELD-TYPE') {
$default_html .= 'CUSTOM HTML FOR FIELD';
}
return $default_html;
}
add_action('arf_outsite_print_style', 'your_function', 10, 3);
function your_function($new_values, $use_saved = '', $form_id = ''){
if (isset($use_saved) and $use_saved) {
//Do Your Action While Saving Form At Editor.
//Get All Styling Options In $new_values.
//Print CSS.
} else {
//Do Your Action While Preview At Form Editor.
//Get All Styling Options In $_REQUEST.
//Print CSS.
}
}
add_filter('arf_change_field_icons_outside', 'your_function', 10, 1);
function your_function($field_icons){
//Update field_icons.
return $field_icons;
}
add_filter('arf_installed_fields_outside', 'your_function', 10, 1);
function your_function($fields){
array_push($fields,'FIELD-TYPE');
return $fields;
}
add_filter('arf_check_for_draw_outside', 'your_function', 10, 2);
function your_function($flag = false, $field){
//Return Field Populate Status.
$flag = true;
return $flag;
}
add_filter('arf_drawthisfieldfromoutside', 'your_function', 10, 4);
function your_function($return_string, $field, $onChange_function, $data_unique_id){
//Draw Form Field
$return_string .= 'Form Field HTML';
return $return_string;
}
add_filter('arf_default_value_array_field_type', 'your_function', 10, 1);
function your_function($field_types){
array_push($field_types,'FIELD-TYPE');
return $field_types;
}
add_filter('arf_default_value_array_field_type_from_itemmeta', 'your_function', 10, 1);
function your_function($field_types){
array_push($field_types,'FIELD-TYPE');
return $field_types;
}
add_filter('arf_field_wise_js_css', 'your_function', 10, 1);
function your_function($fields_js_css = array()){
//Return JS/CSS array for particular field.
$outside_field = array(
'FIELD-TYPE' = array(
'title' => 'FIELD NAME',
'handle' => array(
'js' => array('FIELD-JS'),
'css' => array('FIELD-CSS'),
),
)
);
return array_merge($fields_js_css, $outside_field);
}
add_action('arf_load_bootstrap_js_from_outside', 'your_function', 10, 1);
function your_function($field_type){
if( $field_type == FIELD-TYPE ){
//Do Your Action
echo "enqueue external bootstrap js/css required for field.";
}
}
add_filter('arf_check_for_running_total_field', 'your_function', 10, 5);
function your_function($onChange_function = '', $field = '', $data_unique_id = '', $form = '', $result_data = array()){
//Return string of action on change values.
$onChange_function = " onkeyup='function();'";
return $onChange_function;
}
add_filter('arf_populate_field_from_outside', 'your_function', 10, 3);
function your_function($form_data, $form_id, $values){
//$form_data Form settings values.
//$form_id Form ID
//$values Entry Values.
return $form_data;
}
add_filter('arfbeforefielddisplay', 'your_function', 10, 1);
function your_function($field){
//modify the field here
return $field;
}
add_action('arfafterdisplayfield', 'your_function', 10, 1);
function your_function($field){
//Do Your Action
echo "Form field HTML";
}
add_filter('arfgetdefaultvalue', 'your_function', 10, 2);
function your_function($default_value = '', $field){
//Filter your fields default value.
if($field->type == 'FIELD-TYPE' ){
$default_value = 'SET DEFAULT VALUE';
}
return $default_value;
}
add_filter('arfsetupnewentry', 'your_function', 10, 1);
function your_function($values){
//Customize form or field options.
return $values;
}
add_filter('arfsetupnewfieldsvars', 'your_function', 10, 2);
function your_function($values, $field){
//Customize field values.
return $values;
}
add_filter('arf_disply_required_field_outside', 'your_function', 10, 2);
function your_function($required_flag, $field){
if ($field['type'] == 'FIELD-TYPE') {
$required_flag = false;
}
return $required_flag;
}
add_filter('arf_onchange_only_click_event_outside', 'your_function', 10, 1);
function your_function($field_types){
array_push($field_types,'FIELD-TYPE');
return $field_types;
}
add_filter('arfbeforereplaceshortcodes', 'your_function', 10, 4);
function your_function($html, $field, $error, $form){
//Replace HTML For shortcodes in field HTML.
if($field['type'] == 'FIELD-TYPE') {
$html = str_replace('[CUSTOMCONTENT]', 'CUSTOMCONTENTHTML', $html);
}
return $html;
}
add_filter('arfreplaceshortcodes', 'your_function', 10, 5);
function your_function($html,$field,$fields,$errors,$form){
//Replace shortcodes with field HTML.
if($field['type'] == 'FIELD-TYPE') {
$html = str_replace('[SHORTCODE]', 'HTML CONTENT', $html);
}
return $html;
}
add_filter('arffieldsreplaceshortcodes', 'your_function', 10, 4);
function your_function($value, $tag, $atts, $field){
//Replace shortcodes with field HTML.
if($field->type == 'FIELD-TYPE') {
$value = str_replace('[SHORTCODE]', $atts['entry_id'], $value);
}
return $value;
}
- arf_validateform_outside
This filter is useful to get flag whether form fields are to be validated from outside or not.
- arf_is_validateform_outside
This filter is useful to validate form fields from outside in ARForms.
- arf_validate_form_outside_errors
This filter hook is useful to validate field in form from outside in ARForms.
add_filter('arf_validateform_outside', 'your_function', 10, 2);
function your_function($flag, $form){
//Validate field values.
$flag = true;
return $flag;
}
add_filter('arf_is_validateform_outside', 'your_function', 10, 2);
function your_function($flag, $form){
//Validate field values.
$flag = true;
return $flag;
}
add_filter('arf_validate_form_outside_errors', 'your_function', 10, 4);
function your_function($errors, $form_id, $values, $form_data = array()){
//Validate Form or Fields.
return $errors;
}
- arf_prevent_duplicate_entry
This filter is useful to prevent form submission entry from outside in ARForms.
- arfbeforecreateentry
This hook is useful to perform any action before create entry on submit form.
- arf_before_create_formentry
This filter hook is useful to customize entry to be created after form submission before inserting in database.
- arfaddentrymeta
This filter is useful to change field entry values before inserting in database from outside.
- arfaftercreateentry
This hook is useful to get form entries and perform any action after create entry of submitted form.
- arf_after_create_formentry
This filter hook is useful if to perform action or to prevent further actions to be performed after form submission using created entry data from outside.
- arfdisplayvalue
This filter is useful to display customized entry value from outside in preview as well as in grid of form entries.
- arfdisplayvaluecustom
This filter is useful to display customized entry value from outside in preview of form entries.
- arf_before_destroy_entry
This filter is useful to perform action like to remove uploaded file from upload directory while deleting entry.
- arf_after_destroy_entry
This filter hook is useful to prevent to throw error even entry is not deleted successfully.
add_filter('arf_prevent_duplicate_entry', 'your_function', 10, 3);
function your_function($error_message, $form_id, $values){
//$error_message Error Message to display.
$prevent_entry = true;
return $prevent_entry;
}
add_action('arfbeforecreateentry', 'your_function', 10, 1);
function your_function($values){
//Do Your Action
}
add_filter('arf_before_create_formentry', 'your_function', 10, 1);
function your_function($entry){
//Customize array of entry.
return $entry;
}
add_filter('arfaddentrymeta', 'your_function', 10, 1);
function your_function($values){
//Change field entry value.
return $values;
}
add_action('arfaftercreateentry', 'your_function', 10, 2);
function your_function($entry_id, $form_id){
//Do Your Action
}
add_filter('arf_after_create_formentry', 'your_function', 10, 2);
function your_function($entry_id, $form_id){
$entry_id = false; //Prevent further action to perform after form submission.
return $entry_id;
}
add_filter('arfdisplayvalue', 'your_function', 10, 3);
function your_function($value, $field, $atts){
//Customize particular field entry value.
if($field->type == 'FIELD-TYPE'){
$value = 'CUSTOMIZE ENTRY VALUE';
}
return $value;
}
add_filter('arfdisplayvaluecustom', 'your_function', 10, 3);
function your_function($value, $field, $atts){
//Customize particular field entry value.
if($field->type == 'FIELD-TYPE'){
$value = 'CUSTOMIZE ENTRY VALUE';
}
return $value;
}
add_filter('arf_before_destroy_entry', 'your_function', 10, 1);
function your_function($entry_id){
//Remove uploaded file with this entry.
return $entry_id;
}
add_filter('arf_after_destroy_entry', 'your_function', 10, 1);
function your_function($result){
//If query execution has error
$result = true;
return $result;
}
- arf_change_autoresponse_selected_email_label_in_outside
This filter is useful to change field label to be displayed at email address options list in Email Notifications popup at form editor.
- arf_change_autoresponse_selected_email_value_in_outside
This filter is useful to change on selected field id for email address where email is to be sent at Email Notifications popup.
- arfemailheader
This filter hook is useful to change email header information from outside before seding an email after form submission.
- arfbefore_autoresponse_chnage_mail_address_in_out_side
This filter is useful to change email address from outside where email is to be sent.
- arfbefore_autoresponse_send_mail_body
This filter hook is useful to customize email body content from outside before sending to the user.
- arfbefore_admin_send_mail_body
This filter hook is useful to customize email body content from outside before sending to the admin.
- arfautoresponderattachment
This filter hook is useful to add/change attachments from outside to be sent with an email to user.
- arfnotificationattachment
This filter hook is useful to add/change attachments from outside to be sent with an email.
- arfemailvalue
This filter is useful to customize displaying values for fields in mail content from outside.
- arf_brfore_send_mail_chnage_value
This filter hook is useful to change or customize field entry values from outside before sending mail after form submission successfully.
add_filter('arf_change_autoresponse_selected_email_label_in_outside', 'your_function', 10, 3);
function your_function($selected_field_label, $form_id, $values){
//Change for field label.
return $selected_field_label;
}
add_filter('arf_change_autoresponse_selected_email_value_in_outside', 'your_function', 10, 3);
function your_function($email_field, $form_id, $values){
//Change for field id.
return $email_field;
}
add_filter('arfemailheader', 'your_function', 10, 2);
function your_function($header, $header_array){
//append header information.
$header[] = 'ADD HEADER INFORMATION FOR SENDING MAIL.';
return $header;
}
add_filter('arfbefore_autoresponse_chnage_mail_address_in_out_side', 'your_function', 10, 4);
function your_function($to_email, $email_field, $entry_id, $form_id){
//Change To email address.
$to_email = 'CHANGE EMAIL ADDRESS';
return $to_email;
}
add_filter('arfbefore_autoresponse_send_mail_body', 'your_function', 10, 3);
function your_function($mail_body, $entry_id, $form_id){
//Customize email body content.
$mail_body = str_replace('[SHORTCODE]', 'CUSTOM VALUES', $mail_body);
return $mail_body;
}
add_filter('arfbefore_admin_send_mail_body', 'your_function', 10, 3);
function your_function($mail_body, $entry_id, $form_id){
//Customize email body content.
$mail_body = str_replace('[SHORTCODE]', 'CUSTOM VALUES', $mail_body);
return $mail_body;
}
add_filter('arfautoresponderattachment', 'your_function', 10, 3);
function your_function($attachments, $form, $entry){
//Add or Customize Attachments.
$attachments[] = 'ADD NEW ATTACHEMENT';
return $attachments;
}
add_filter('arfnotificationattachment', 'your_function', 10, 3);
function your_function($attachments, $form, $entry){
//Add or Customize Attachments.
$attachments[] = 'ADD NEW ATTACHEMENT';
return $attachments;
}
add_filter('arfemailvalue', 'your_function', 10, 3);
function your_function($entry_value, $field, $entry){
//Customize entry values.
$entry_value = 'CUSTOMIZE ENTRY VALUE';
return $entry_value;
}
add_filter('arf_brfore_send_mail_chnage_value', 'your_function', 10, 3);
function your_function($field, $entry_id, $form_id){
//Customize field values.
if($field->field_type == 'FIELD-TYPE'){
$field->entry_value = 'CUSTOMIZE ENTRY VALUE';
}
return $field;
}
- arfcsvwhere
This filter hook is useful to get records filtered to be exported in CSV file by returning where clause for database query.
- arfcsvvalue
This filter hook is useful to customize values from outside to be exported in CSV File.
- arfcsvdateformat
This filter hook is useful to change date format for Timestamp in exported CSV file.
add_filter('arfcsvwhere', 'your_function', 10, 2);
function your_function($where_clause = '', $form_ids){
//Return where condition to get records exported in CSV.
$where_clause .= 'WHERE CLAUSE';
return $where_clause;
}
add_filter('arfcsvvalue', 'your_function', 10, 2);
function your_function($checked_values, $fields_col = array()){
//Filter your fields value.
return $checked_values;
}
add_filter('arfcsvdateformat', 'your_function', 10, 1);
function your_function($datetime_format = 'Y-m-d H:i:s'){
$datetime_format = 'd-m-Y H:i:s';
return $datetime_format;
}
- wp_arf_footer
This action hook is useful to load external js/css for fields which are added from outside in ARForms.
add_action('wp_arf_footer', 'your_function', 10, 1);
function your_function($loaded_fields){
//Do Your Action
//enqueue external js/css required for field.
}