options =& $sportspress_options; add_action( 'admin_init', array( $this, 'page_init' ), 1 ); } function page_init() { register_setting( 'sportspress_general', 'sportspress', 'sportspress_options_validate' ); add_settings_section( 'general', __( 'General Options', 'sportspress' ), '', 'sportspress_general' ); add_settings_field( 'sport', __( 'Sport', 'sportspress' ), array( $this, 'sport_callback' ), 'sportspress_general', 'general' ); } function sport_callback() { global $sportspress_options; $selected = sportspress_array_value( $sportspress_options, 'sport', null ); $custom_sport_name = sportspress_array_value( $sportspress_options, 'custom_sport_name', null ); ?>
class="hidden">