Set new value with dependent() is not working
Set new value with dependent() is not working
Ronald76
Posts: 4Questions: 2Answers: 0
hi together,
i try to update a value in database,
if the value in a field "main_menu" is by "1" the field "sub_menu" need the value "0".
I think about a code like this:
editor.dependent( 'main_menu', function ( val ) {
if (val == '1') {
editor.field( 'sub_menu').val("0");
}
});
whatever i try to set the value doesnt work. maybe i can get help here?
Thanks
Ronny
This discussion has been closed.