The price form on the submit listing page,
It shows a decimal point when I click the up or down bar.
The Japanese Yen does not have a decimal point so I want to avoid it.
How can I do that?
The price form on the submit listing page,
It shows a decimal point when I click the up or down bar.
The Japanese Yen does not have a decimal point so I want to avoid it.
How can I do that?
Please try this PHP snippet
add_filter(
'hivepress/v1/forms/listing_update',
function( $form ) {
if ( isset( $form['fields']['price'] ) ) {
$form['fields']['price']['type'] = 'number';
$form['fields']['price']['min_value'] = 0;
$form['fields']['price']['decimals'] = 0;
}
return $form;
},
1000
);
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.