Hi,
I have a problem with the users CRED modify form. I have a checkbox field and appear always checked. I would that the checkbox is checked when the value is 0 and the checkbox not checked when value is 1. This checkbox field is a custom user field.
In short, I have to set the default value in the opposite way that the value is stored in database.
I'm not sure what you mean but this is my interpretation. Is it that you want this checkbox to not be checked by default and when it is not checked the value is set to 1 and when it is checked the value set to 0?
Hi Shane,
I have to modify value of the checkbox without touch it. For example I have a field that is called "status". If status value is set 1 in db, I have to see the checkbox unchecked, if the value of status is 0, I have to see checkbox checked.
So this custom field is hidden from the users? And you want to change the value being checked or not checked through the database correct?
In evaluating it though the frontend using 1 or 0 shouldn't matter its just what you represent as check and uncheck. So lets say you want all the customers who don't have the checkbox checked.
Not checked is represented by 1 and if you set the filters to display all the users with 1.
Please let me know if you are clear on what i'm saying.
- USER 1 [x]custom_field [SAVE]
- USER 2 [ ]custom_field [SAVE]
- USER 3 [ ]custom_field [SAVE]
- USER 4 [ ]custom_field [SAVE]
- USER 5 [x]custom_field [SAVE]
- USER 6 [ ]custom_field [SAVE]
- USER 7 [x]custom_field [SAVE]
[x] is when value on db is set to 0, so if I click on "SAVE" button the value is change to 1
[ ] is when value on db is set to 1, so if I click on "SAVE" button the value is change to 0