I have added my own content type with many fields to enter, I want to hide some fields when adding a content according to radio button selection. I explain, in the add content page, i have two radio buttons (inside/outside) and inside is selected by default and some fields are hidden, when user select outside, some fields will be hidden and the fields accorded to outside will be shown to user to fill them. How to do this ?
1 Answer
You are looking for Conditional Field Module...
Define dependencies between fields based on their states and values.
Conditional Fields for Drupal 7 is an user interface to the new States API, plus the ability to modify fields appearance and behavior on certain conditions when viewing content.
-
Ok i will try this, If hidden fields are required, ihave to change that property or content will be added even if they are required ? Aug 28, 2014 at 15:13
-
Yes, I believe it's general use case and module should support same... Aug 28, 2014 at 15:14
-
Is it possible to do it without this module, as for the same machine names permissions are inherited? May 3, 2016 at 3:40