Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function edit_term( $term_id, $tt_id, $taxonomy ) {
- global $wpdb;
- $term = get_term( $term_id, $taxonomy );
- $slug = FWP()->helper->safe_value( $term->slug ); // MD5 Hebrew
- $wpdb->query( $wpdb->prepare( "
- UPDATE {$wpdb->prefix}facetwp_index
- SET facet_value = %s, facet_display_value = %s
- WHERE facet_source = %s AND term_id = %d",
- $slug, $term->name, "tax/$taxonomy", $term_id
- ) );
- }
Add Comment
Please, Sign In to add comment