I need something similar to the "validation" mod, but simpler. I have a checkbox field called "visible"... All default searches have the visible=1 appended in a hidden field and the admin can thus turn a record visibility on and off.
here are my questions:
1) is it possible to create a checkbox where it automatically enter a "0" or a "1" based on the checked status. I have played with the "0,1" settings:
%db_checkbox_fields = ('Visible' => '1,0'); but they don't seem to do the job
2) when I search with the check box unchecked hoping I will return all the invisible (0) records, it failed... I guess it has something to do with my first question....
3) is there a better way to do this... JPDeni's validation code incorporate sending email to form submitter of the validation, which I don't want, plus the use of a single radio button, making it not very easy to turn off, once on.
Thank you in advance
here are my questions:
1) is it possible to create a checkbox where it automatically enter a "0" or a "1" based on the checked status. I have played with the "0,1" settings:
Code:
'Visible' => [10, 'alpha', 0, 3, 1, '0', '1,0'], %db_checkbox_fields = ('Visible' => '1,0');
2) when I search with the check box unchecked hoping I will return all the invisible (0) records, it failed... I guess it has something to do with my first question....
3) is there a better way to do this... JPDeni's validation code incorporate sending email to form submitter of the validation, which I don't want, plus the use of a single radio button, making it not very easy to turn off, once on.
Thank you in advance