Round robin assignments

add_filter( ‘frm_validate_field_entry’, ‘frm_set_value_based_on_order’, 15, 3 ); function frm_set_value_based_on_order( $errors, $posted_field, $posted_value ) { if ( $posted_field->id == 175 ) { //change 175 to the ID of your group name field $group_id = $_POST[‘item_meta’][174] % 2;//change 174 to your auto_id field…Continue reading

Remove Extra Address Columns on Export

add_filter( ‘frm_csv_columns’, ‘remove_extra_address_columns’, 10, 2 ); function remove_extra_address_columns( $headings, $form_id ) { if ( $form_id == 568 ) { //change 568 to your Form ID $address_field_id = ‘3855’; //change 3855 to your Address Field ID unset( $headings[$address_field_id . ‘_line1’] );…Continue reading

Use a custom URL

add_filter( ‘frm_jquery_ui_base_url’, ‘change_google_url’ ); function change_google_url( $url ) { return ‘http://example.com/’; }Continue reading

Basic Example

add_filter(‘frm_graph_value’, ‘my_custom_graph_value’, 10, 2); function my_custom_graph_value( $value, $field ) { if ( $field->id == 123 ) { $value = ‘new value’; } return $value; }Continue reading

Show substring of an entry

add_filter( ‘frmpro_fields_replace_shortcodes’, ‘frm_substr_shortcode’, 10, 4 ); function frm_substr_shortcode( $replace_with, $tag, $atts, $field ) { if ( isset( $atts[‘length’] ) ) { $start = isset( $atts[‘start’] ) ? $atts[‘start’] : 0; $replace_with = substr( $replace_with, $start, $atts[‘length’] ); } elseif (…Continue reading

Add a page anchor

add_filter( ‘frm_prev_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_first_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_last_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_next_page_link’, ‘change_pagination_link’, 10, 2 ); function change_pagination_link( $link, $atts ) { if ( $atts[‘view’]->ID ===…Continue reading

Change the page parameter

add_filter( ‘frm_prev_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_first_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_last_page_link’, ‘change_pagination_link’, 10, 2 ); add_filter( ‘frm_next_page_link’, ‘change_pagination_link’, 10, 2 ); function change_pagination_link( $link, $atts ) { if ( $atts[‘view’]->ID ===…Continue reading

Automatically update a field in another form

add_action(‘frm_after_create_entry’, ‘link_fields’, 30, 2); add_action(‘frm_after_update_entry’, ‘link_fields’, 10, 2); function link_fields($entry_id, $form_id){ if($form_id == 113){//Change 113 to the ID of the first form global $wpdb; $first_field = $_POST[‘item_meta’][25]; //change 25 to the ID of the field in your first form $user…Continue reading