JoeSz / Exopite-Simple-Options-Framework

Fast, easy and lightweight admin options/metabox form generator for WordPress Plugins and metaboxes.
GNU General Public License v3.0
78 stars 24 forks source link

the dependency field option not working #39

Open KingMatrix1989 opened 1 year ago

KingMatrix1989 commented 1 year ago

Hi. There seems to be a problem with the dependency feature. Also, the demo plugin has been checked.

The following code (from demo plugin) not working:

array(
    'id'    => 'checkbox_1',
    'type'  => 'checkbox',
    'title' => 'Checkbox',
    'label' => 'Did you like this framework ?',
    'after' => '<i>If you check this and the other checkbox, a text field will appier.</i>'
),

array(
    'id'    => 'checkbox_2',
    'type'  => 'checkbox',
    'title' => 'Checkbox Fancy',
    'label' => 'Do you want to do this?',
    'style'    => 'fancy',
),

array(
    'id'     => 'text_2',
    'type'   => 'text',
    'title'  => 'Text Test Dependency',
    'dependency' => array( 'checkbox_1|checkbox_2', '==|==', 'true|true' ),
    'attributes'    => array(
        'placeholder' => 'Dependency test',
    ),
),
JoeSz commented 1 year ago

Hi, I just installed a clean WP and the demo plugin from GitHub and everything is working. So you have to be more specific :)

KingMatrix1989 commented 1 year ago

Hi. What version of WordPress do you have installed?