Hi, I have an issue displaying the prices correctly on my web. As I live in Spain I need the prices to show with a , delimiter instead of the .
As I didn’t see anywhere in the ACF plugin an option to change this I’ve tried adding the following function to my child theme
function cambiar_delimitador_precio($value, $post_id, $field) {
$value = str_replace('.', ',', $value);
return $value;
}
add_filter('acf/format_value/type=price', 'cambiar_delimitador_precio', 20, 3);
But it has no effect.
An example it can be seen here: https://staging.ciudadrealfibra.net/tarifa/1000mb-simetrico/
Many thanks for your help!
... acf/format_value/type=price' .....
There is not field type of “price” is price the field name? If it is then the hook should be
acf/format_value/name=price
Thanks a lot! this worked 🙂