You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Not sure if there is any intention to make this work properly but in the old days, there was a number type field and also there is a number_validation option on text fields but neither of them seem to work at all in the Visual Builder and even on the backend side there are a few problems.
The settings I found in the core looked promising:
When used, they have no effect though. Furthermore if 'number_validation' is turned on, you can only enter number of 0-100 in the BB and in the VB you can still enter characters.
I'd love to see a proper number field. Currently I mostly rely on range fields to enter numbers but this is not always a good solution. For example I have a number counter module and the user can enter any number but also letters as the field is a textfield.
Sure, I sanitize the field in my code but it would be more convenient if a user couldn't enter letters at all. A number field or a option on text fields to make sure the entered number is actually a number (int or float) would be great and it would be even better if it worked in the VB as well.
The problem with the range field is, that it is not obvious for the user that he can enter any number if desired, even if it's outside of the range of the slider. I'd really like to see a setting like this:
'a_number' => array(
'label' => esc_html__( 'A number', 'et_builder' ),
'description' => esc_html__( 'Enter a number or leave empty to use the default value of 125', 'et_builder' ),
'type' => 'number',
'default' => 125,
'value_type' => 'int', //or 'float'
'step' => 25, //or 132.2
'option_category' => 'basic_option',
'toggle_slug' => 'main_content',
),
Implementation shouldn't be to hard I believe. Its basically a range field but without the slider. I hope you understand what I mean. :)
The text was updated successfully, but these errors were encountered:
Problem Description
Not sure if there is any intention to make this work properly but in the old days, there was a
number
type field and also there is anumber_validation
option ontext
fields but neither of them seem to work at all in the Visual Builder and even on the backend side there are a few problems.The settings I found in the core looked promising:
When used, they have no effect though. Furthermore if 'number_validation' is turned on, you can only enter number of 0-100 in the BB and in the VB you can still enter characters.
I'd love to see a proper
number
field. Currently I mostly rely onrange
fields to enter numbers but this is not always a good solution. For example I have a number counter module and the user can enter any number but also letters as the field is a textfield.Sure, I sanitize the field in my code but it would be more convenient if a user couldn't enter letters at all. A number field or a option on text fields to make sure the entered number is actually a number (int or float) would be great and it would be even better if it worked in the VB as well.
The problem with the
range
field is, that it is not obvious for the user that he can enter any number if desired, even if it's outside of the range of the slider. I'd really like to see a setting like this:Implementation shouldn't be to hard I believe. Its basically a
range
field but without the slider. I hope you understand what I mean. :)The text was updated successfully, but these errors were encountered: