Support

Account

Home Forums General Issues Insert Commas into ACF number field Reply To: Insert Commas into ACF number field

  • Can someone explain where this snippet of code goes in WP in order to get the comma inserted in the numeric field?

    add_filter(‘acf/format_value/type=number’, ‘fix_number’, 30, 3);
    function fix_number($value, $post_id, $field) {
    $value = number_format($value);
    return $value;
    }