Unprotect temporary files for one form

add_filter( ‘frm_protect_temporary_file’, ‘unprotect_temporary_files’, 10, 2 ); function unprotect_temporary_files( $protect, $args ) { $target_form_id = 117; // change 117 to the ID of your form if ( $target_form_id === (int) $args[‘form_id’] && FrmProFileField::file_is_an_image( $args[‘file_id’] ) ) { $protect = false; }…Continue reading

Unprotect temporary files for all forms

add_filter( ‘frm_protect_temporary_file’, ‘unprotect_temporary_files’, 10, 2 ); function unprotect_temporary_files( $protect, $args ) { if ( FrmProFileField::file_is_an_image( $args[‘file_id’] ) ) { $protect = false; } return $protect; }Continue reading

Order dynamic options with conditionals

add_filter(‘frm_data_sort’, ‘frm_data_sort_conditional’, 30, 2); function frm_data_sort_conditional($options, $args) { $target_field_id = 100; // Change 100 to the child field ID. if ( $target_field_id === (int) $args[‘dynamic_field’][‘id’] ) { ksort( $options ); } return $options; }Continue reading

Sort or remove fields

add_filter( ‘frm_entry_values_fields’, ‘sort_remove_fields’, 10, 2 ); function sort_remove_fields( $fields, $args ) { // Do anything with the $fields. // Your code here… return $fields; }Continue reading

Specify a field to exclude

add_filter( ‘frm_entry_values_exclude_fields’, ‘specify_exclude_fields’, 10, 2 ); function specify_exclude_fields( $field_ids, $atts ) { $field_ids[] = 3013; return $field_ids; }Continue reading

Set x-axis options

add_filter(‘frm_google_chart’, ‘frm_add_haxis_options’, 10, 2); function frm_add_haxis_options( $options, $atts ){ $options[‘hAxis’]= array( ‘textStyle’ => array( ‘color’ => ‘green’, ‘fontSize’ => ’18’, ‘bold’=> true ) ); return $options; }Continue reading

Remove a specific field from CSV export

add_filter( ‘frm_fields_for_csv_export’, ‘remove_specific_field_from_csv_export’, 10, 2 ); function remove_specific_field_from_csv_export( $fields, $args ) { $target_form_id = 220; // change 220 to the ID of the form if ( $target_form_id === (int) $args[‘form’]->id ) { $target_field_id = 1204; // change 1204 to the…Continue reading

Limit event registration

add_filter( ‘frm_validate_entry’, ‘event_registration’, 20, 2 ); function event_registration( $errors, $values ) { if ( $values[‘form_id’] !== 304 ) {//Change 304 to the ID of your form return $errors; } $registration_field = 3080;// Set this field to the id of the…Continue reading