I have dropdown menu that has this as the values:
'options' => array( '' => 'Show', 'afd3generalsettings' => 'Hide',
This is the code I'm using to pull the data, but it throws an error until i actually select "hide" then the error goes away. I can not seem to set a default value.
include dirname(__FILE__) . get_option( 'afd3generalsettings') ;
even if I set two values in the array, for both "show & hide" it will not set a default when the plugin is loaded. I tried something like this...
include dirname(__FILE__) . get_option( 'afd3generalsettings', 'default.css') ;
Thinking it would set a default of the second value. But it doesn't work. I just need to set a default value to nothing or for it to check and see that's its null and thats ok?
This is the error I get:
Warning: include(/Users/vladic/Sites/dashplugin/wp-content/plugins/wp_agency_dashboard_v3): failed to open stream: Undefined error: 0 in /Users/vladic/Sites/dashplugin/wp-content/plugins/wp_agency_dashboard_v3/afd3_dashboard.php on line 32