'. __( 'Options saved successfully.', 'add-to-feed' ) .'
'; echo $str; } if ( isset( $_POST['atf_default'] ) && check_admin_referer( 'atf-admin-options' ) ) { delete_option( 'ald_atf_settings' ); $atf_settings = atf_default_options(); update_option( 'ald_atf_settings', $atf_settings ); $str = ''. __( 'Options set to Default.', 'add-to-feed' ) .'
' . sprintf( __( 'Add to Feed plugin is disabled. Please visit the plugin settings page to enable the plugin or disable this notice.', 'add-to-feed' ), $plugin_settings_page ) . '
'; } add_action( 'admin_notices', 'atf_admin_notice' ); /** * Add menu item in WP-Admin. * */ function atf_adminmenu() { $plugin_page = add_options_page( __( "Add to Feed", 'add-to-feed' ), __( "Add to Feed", 'add-to-feed' ), 'manage_options', 'atf_options', 'atf_options'); add_action( 'admin_head-'. $plugin_page, 'atf_adminhead' ); } add_action( 'admin_menu', 'atf_adminmenu' ); /** * Function scripts to Admin head. * * @access public * @return void */ function atf_adminhead() { global $atf_url; wp_enqueue_script( 'common' ); wp_enqueue_script( 'wp-lists' ); wp_enqueue_script( 'postbox' ); ?>