Tagged: conditions, Multi-select fields
- This topic has 2 replies, 2 voices, and was last updated 6 years ago by
Steve.
-
AuthorPosts
-
-
February 7, 2016 at 2:04 am #5870
rafiMemberQuestion related to conditionals:
When selecting more than one item on a multi-select box, Only the first selected item will trigger.
The rest are ignored. On the example below if you select on the multiple select field: ‘prefecture’
‘Aichi’ the hidden field aichi_city will show. Selecting an additional item will not show any other field.
Is there a way to show other fields by selecting the respective items on the field: ‘prefecture’?piklist(‘field’, array(
‘type’ => ‘select’
,’scope’ => ‘user_meta’
,’field’ => ‘prefecture’
,’label’ => ‘Prefecture’
,’attributes’ => array(
‘class’ => ‘text’
, ‘multiple’ => ‘multiple’
)
,’choices’ => array(
Aichi’ => ‘Aichi’
,’Akita’ => ‘Akita’
,’Aomori’ => ‘Aomori’
,’Chiba’ => ‘Chiba’
,’Ehime’ => ‘Ehime’
)));piklist(‘field’, array(
‘type’ => ‘text’
,’scope’ => ‘user_meta’
,’field’ => ‘aichi_city’
,’label’ => ‘Aichi city’
,’conditions’ => array(
array(
‘field’ => ‘prefecture’
,’value’ => ‘Aichi’
)
)
));piklist(‘field’, array(
‘type’ => ‘text’
,’scope’ => ‘user_meta’
,’field’ => ‘aichi_city’
,’label’ => ‘Aichi city’
,’conditions’ => array(
array(
‘field’ => ‘prefecture’
,’value’ => ‘Aichi’
)
)
));piklist(‘field’, array(
‘type’ => ‘text’
,’scope’ => ‘user_meta’
,’field’ => ‘akita_city’
,’label’ => ‘Akita city’
,’conditions’ => array(
array(
‘field’ => ‘prefecture’
,’value’ => ‘Aichi’
)
)
));piklist(‘field’, array(
‘type’ => ‘text’
,’scope’ => ‘user_meta’
,’field’ => ‘aomori_city’
,’label’ => ‘Aomori city’
,’conditions’ => array(
array(
‘field’ => ‘prefecture’
,’value’ => ‘Aomori’
)
)
)); -
February 8, 2016 at 2:03 pm #5876
SteveKeymasterThis reply has been marked as private. -
February 8, 2016 at 2:04 pm #5877
-
-
AuthorPosts
- You must be logged in to reply to this topic.