Could you help, please, to understand how to save the settings correctly in the next case?
function my_settings_init() { ... register_setting( 'my-settings-group', 'my-settings-name' ); add_settings_field( 'my-field, 'My Field', 'my_field_callback', 'my-plugin', 'my-section' ); ... } function my_field_fallback() { $setting = get_option( 'my-settings-name' ); echo 'input type='text' name='my-settings-name[title]'; echo 'input type='text' name='my-settings-name[slug]'; }
The result array is:
Array ( [title] => title 1 [slug] => slug 1 )
How to use save_callback to make the next result:
Array ( [0] => Array ( [title] => title 1 [slug] => slug 1 ) [1] => Array ( [title] => title 2 [slug] => slug 2 ) ... )
Thank you for your help!