Action: RML/Options/Register

do_action( 'RML/Options/Register' )

Allows you to register new options tabs and fields to the Real Media Library options panel (Settings > Media).

Example

Create a new tab with a settings field

add_action( 'RML/Options/Register', function() {
 // Register tab
 add_settings_section(
     'rml_options_custom',
     __('RealMediaLibrary:My Tab'), // The label must begin with RealMediaLibrary:
     [MatthiasWeb\RealMediaLibrary\view\Options::getInstance(), 'empty_callback'),
     'media'
 );

 add_settings_field(
     'rml_button_custom',
     '<label for="rml_button_custom">Your custom button</label>' ,
     'my_function_to_print_rml_button_custom',
     'media',
     'rml_options_custom' // The section
 );
} );