In my form, there are 3 selection list A, B and C.
I wanna show or hide C based on values of A and B selected. C should be shown if A's value = 'all and B's value != 'all'
How to set the #state condition in this case?
$form['C'] = array(
'#type' => 'select',
'#title' => t('C'),
'#states' => array(
'visible' => array(
':input[name="A"]' => array('value' => 'all'),
':input[name="B"]' => array('value' => 'all') //???how to set !='all' here?
)
)
)